Open jrfnl opened 7 months ago
Is there any news on this? Dependencies seem to be released.
@leitommi What dependencies are you talking about ?
I mean these PR-s are merged that were marked as "Blocked until": https://github.com/PHPCSStandards/PHP_CodeSniffer/pull/49 https://github.com/PHPCSStandards/PHP_CodeSniffer/pull/78
I am mostly interested in typed class constants that were introduced in php 8.3.
Currently following code:
class A
{
const int $MY_VAL;
}
produces following error, with phpcs 3.8.0:
phpcs: Generic.NamingConventions.UpperCaseConstantName.ClassConstantNotUpperCase: Class constants must be uppercase; expected INT but found int
For whoever cares - PR #309 is open adding tokenizer support for readonly anonymous classes and PR #321 adding tokenizer support for typed class constants.
Once those two are merged, support can be added to individual sniffs (and yes, the commits for this are ready and waiting).
The following three PRs have been opened to add support for PHP 8.3 typed class constants to various sniffs:
Testing of these PRs would be appreciated.
The following three PRs have been opened to add support for PHP 8.3 typed class constants to various sniffs:
- PHP 8.3 | Generic/LowerCaseConstant: add support for typed constants #330
- PHP 8.3 | Generic/LowerCaseType: add support for typed constants #331
- PHP 8.3 | Generic/UpperCaseConstantName: add support for typed constants #332
Testing of these PRs would be appreciated.
Everything works as expected for me.✌️👍 When can we expect a release?
The following three PRs have been opened to add support for PHP 8.3 typed class constants to various sniffs:
- PHP 8.3 | Generic/LowerCaseConstant: add support for typed constants #330
- PHP 8.3 | Generic/LowerCaseType: add support for typed constants #331
- PHP 8.3 | Generic/UpperCaseConstantName: add support for typed constants #332
Testing of these PRs would be appreciated.
I can also confirm that everything is working correctly. 👍
@FabianKoestring @KeldorDE Thank you both for testing. Unless something unexpected happens, I'm hoping to release the 3.9.0 version towards the end of next week.
PHP 8.3 includes the following new syntaxes for which it should be verified if the Tokenizer needs updates and/or whether any sniffs need updates:
To Do
C::{$name}
yield from
- see #529Done
new readonly class {};
Updates needed to utility functions -getClassProperties()
Blocked until PR squizlabs/PHP_CodeSniffer#3662 / #49 has been merged.Blocked until PR squizlabs/PHP_CodeSniffer#3867 / #78 has been merged.