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

Squiz/SelfMemberReference: handle namespace declaration ending on PHP close tag #555

Merged

Conversation

jrfnl
Copy link
Member

@jrfnl jrfnl commented Jul 16, 2024

Description

This change prevents an edge-case false negative for a namespaced self reference, when the namespace declaration would be ended by a PHP close tag instead of the expected T_SEMICOLON or T_OPEN_CURLY_BRACE.

Includes unit test.

Suggested changelog entry

Squiz.Classes.SelfMemberReference: prevent edge case false negative when the namespace declaration would end on a PHP close tag.

Related issues/external references

Related to #552

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
… close tag

This change prevents an edge-case false negative for a namespaced self reference, when the namespace declaration would be ended by a PHP close tag instead of the expected `T_SEMICOLON` or `T_OPEN_CURLY_BRACE`.

Includes unit test.

Related to 552
@jrfnl jrfnl force-pushed the feature/552-squiz-selfmemberreference-bugfix-close-tag branch from 57935d0 to 783371a Compare July 19, 2024 18:59
@jrfnl
Copy link
Member Author

jrfnl commented Jul 19, 2024

Rebased without changes to get this ready for merge tomorrow.

@jrfnl jrfnl merged commit 64c2c23 into master Jul 20, 2024
48 checks passed
@jrfnl jrfnl deleted the feature/552-squiz-selfmemberreference-bugfix-close-tag branch July 20, 2024 04:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment