Skip to content

Conversation

jrfnl
Copy link
Member

@jrfnl jrfnl commented Jun 13, 2025

Universal/DuplicateArrayKey: add extra tests

Numeric strings which do not comply with the rules for PHP 7.4 numeric literals with underscores should not be regarded as numeric array indexes.
This bug was fixed in PHPCSUtils 1.1.0.

This commit adds some tests to safeguard the fix in the sniff for which this problem was originally reported.

See PHPCSStandards/PHPCSUtils#619

Universal/DuplicateArrayKey: add tests with FQN true/false

Related to PHPCSStandards/PHPCSUtils#668

jrfnl added 2 commits June 13, 2025 16:43
Numeric strings which do not comply with the rules for PHP 7.4 numeric literals with underscores should not be regarded as numeric array indexes.
This bug was fixed in PHPCSUtils 1.1.0.

This commit adds some tests to safeguard the fix in the sniff for which this problem was originally reported.

See PHPCSStandards/PHPCSUtils 619
Related to PHPCSStandards/PHPCSUtils 668
@jrfnl jrfnl added this to the 1.3.x Next milestone Jun 13, 2025
@jrfnl jrfnl merged commit 681f43e into develop Jun 13, 2025
62 checks passed
@jrfnl jrfnl deleted the feature/universal-duplicatearraykey-add-extra-tests branch June 13, 2025 15:05
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.

1 participant