Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

File::findExtendedClassName() doesn't support nested classes #2127

Merged

Conversation

jrfnl
Copy link
Contributor

@jrfnl jrfnl commented Aug 19, 2018

The method used the class scope closer to end searches, which meant that a non-extended class which contained a nested extended class would return the extended class name of the nested class, instead of false.

Switching this to the scope opener, fixes this.

Included unit tests.

The method used the class scope closer to end searches, which meant that a non-extended class which contained a nested extended class would return the extended class name of the nested class, instead of `false`.

Switching this to the scope opener, fixes this.

Included unit tests.
@gsherwood gsherwood added this to the 3.3.2 milestone Aug 20, 2018
@gsherwood gsherwood changed the title File::findExtendedClassName(): bugfix with nested classes File::findExtendedClassName() doesn't support nested classes Aug 20, 2018
@gsherwood gsherwood merged commit a3232a6 into squizlabs:master Aug 20, 2018
gsherwood added a commit that referenced this pull request Aug 20, 2018
@gsherwood
Copy link
Member

That's a strange one. I wonder why I would have picked the scope closer over the opener when looking for an extends keyword 🤷‍♂️

Thanks for fixing it.

@jrfnl jrfnl deleted the feature/bugfix-find-extended-class branch August 20, 2018 07:29
@jrfnl
Copy link
Contributor Author

jrfnl commented Aug 20, 2018

You're welcome.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants