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

Request: option to ignore octal numbers in RequireNumericLiteralSeparatorSniff #1324

Closed
weirdan opened this issue Jan 5, 2022 · 2 comments
Closed
Milestone

Comments

@weirdan
Copy link

weirdan commented Jan 5, 2022

Currently with minDigitsBeforeDecimalPoint=3 this sniff enforces separator presence even for octal numbers, e.g. chmod($filename, 0666) should be spelled chmod($filename, 0_666). However, it's not how people are used to spell permissions, even if they want decimal numbers spelt as 3_456.

weirdan added a commit to weirdan/psalm that referenced this issue Jan 5, 2022
I would like to set minDigitsBeforeDecimalPoint to 4, but it causes
false positives with octal numbers (slevomat/coding-standard#1324).
@kukulich
Copy link
Contributor

kukulich commented Jan 5, 2022

Implemented in 3d9522d

@kukulich kukulich closed this as completed Jan 5, 2022
@kukulich kukulich added this to the 8.0 milestone Jan 5, 2022
@github-actions
Copy link

github-actions bot commented Feb 6, 2022

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Feb 6, 2022
@kukulich kukulich modified the milestones: 8.0, 7.1 Mar 29, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants