You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: CHANGELOG.md
+88
Original file line number
Diff line number
Diff line change
@@ -6,6 +6,93 @@ The file documents changes to the PHP_CodeSniffer project.
6
6
7
7
_Nothing yet._
8
8
9
+
## [3.11.0] - 2024-11-12
10
+
11
+
### Added
12
+
- Runtime support for PHP 8.4. All known PHP 8.4 deprecation notices have been fixed.
13
+
- Syntax support for new PHP 8.4 features will follow in a future release.
14
+
- If you find any PHP 8.4 deprecation notices which were missed, please report them.
15
+
- Thanks to [Juliette Reinders Folmer][@jrfnl] for the patches.
16
+
- Tokenizer support for PHP 8.3 "yield from" expressions with a comment between the keywords. [#529], [#647]
17
+
- Sniffs explicitly handling T_YIELD_FROM tokens may need updating. The PR description contains example code for use by sniff developers.
18
+
- Additionally, the following sniff has been updated to support "yield from" expressions with comments:
19
+
- Generic.WhiteSpace.LanguageConstructSpacing
20
+
- Thanks to [Juliette Reinders Folmer][@jrfnl] for the patch.
21
+
- New `Generic.WhiteSpace.HereNowdocIdentifierSpacing` sniff. [#586], [#637]
22
+
- Forbid whitespace between the `<<<` and the identifier string in heredoc/nowdoc start tokens.
23
+
- Thanks to [Juliette Reinders Folmer][@jrfnl] for the patch.
24
+
- New `Generic.Strings.UnnecessaryHeredoc` sniff. [#633]
25
+
- Warns about heredocs without interpolation or expressions in the body text and can auto-fix these to nowdocs.
26
+
- Thanks to [Juliette Reinders Folmer][@jrfnl] for the patch.
27
+
- Documentation for the following sniffs:
28
+
- Generic.Arrays.ArrayIndent
29
+
- Squiz.PHP.Heredoc
30
+
- Thanks to [Rodrigo Primo][@rodrigoprimo] and [Juliette Reinders Folmer][@jrfnl] for the patches.
31
+
32
+
### Changed
33
+
- The Common::getSniffCode() method will now throw an InvalidArgumentException exception if an invalid `$sniffClass` is passed. [#524], [#625]
34
+
- Thanks to [Juliette Reinders Folmer][@jrfnl] for the patch.
35
+
- Documentation generated using the `--generator=...` feature will now always be presented in natural order based on the sniff name(s). [#668]
36
+
- Thanks to [Juliette Reinders Folmer][@jrfnl] for the patch.
37
+
- Minor improvements to the display of runtime information. [#658]
38
+
- Thanks to [Juliette Reinders Folmer][@jrfnl] for the patch.
39
+
- Squiz.Commenting.PostStatementComment: trailing annotations in PHP files will now be reported under a separate, non-auto-fixable error code `AnnotationFound`. [#560], [#627]
40
+
- This prevents (tooling related) annotations from taking on a different meaning when moved by the fixer.
41
+
- The separate error code also allows for selectively excluding it to prevent the sniff from triggering on trailing annotations, while still forbidding other trailing comments.
42
+
- Thanks to [Rodrigo Primo][@rodrigoprimo] for the patch.
43
+
- Squiz.ControlStructures.ForEachLoopDeclaration: the `SpacingAfterOpen` error code has been replaced by the `SpaceAfterOpen` error code. The latter is a pre-existing code. The former appears to have been a typo. [#582]
44
+
- Thanks to [Dan Wallis][@fredden] for the patch.
45
+
- The following sniff(s) have received efficiency improvements:
46
+
- Generic.Classes.DuplicateClassName
47
+
- Generic.NamingConventions.ConstructorName
48
+
- Thanks to [Rodrigo Primo][@rodrigoprimo] and [Juliette Reinders Folmer][@jrfnl] for the patches.
49
+
- Various housekeeping, including improvements to the tests and documentation.
50
+
- Thanks to [Rodrigo Primo][@rodrigoprimo] and [Juliette Reinders Folmer][@jrfnl] for their contributions.
51
+
52
+
### Fixed
53
+
- Fixed bug [#3808][sq-3808] : Generic.WhiteSpace.ScopeIndent would throw false positive for tab indented multi-token yield from expression.
54
+
- Thanks to [Juliette Reinders Folmer][@jrfnl] for the patch
55
+
- Fixed bug [#630] : The tokenizer could inadvertently transform "normal" parentheses to DNF parentheses, when a function call was preceded by a switch-case / alternative syntax control structure colon.
56
+
- Thanks to [Juliette Reinders Folmer][@jrfnl] for the patch
57
+
- Fixed bug [#645] : On PHP 5.4, if yield was used as the declaration name for a function declared to return by reference, the function name would incorrectly be tokenized as T_YIELD instead of T_STRING.
58
+
- Thanks to [Juliette Reinders Folmer][@jrfnl] for the patch
59
+
- Fixed bug [#647] : Tokenizer not applying tab replacement in single token "yield from" keywords.
60
+
- Thanks to [Juliette Reinders Folmer][@jrfnl] for the patch
61
+
- Fixed bug [#647] : Generic.WhiteSpace.DisallowSpaceIndent did not flag space indentation in multi-line yield from.
62
+
- Thanks to [Juliette Reinders Folmer][@jrfnl] for the patch
63
+
- Fixed bug [#647] : Generic.WhiteSpace.DisallowTabIndent did not flag tabs inside yield from.
64
+
- Thanks to [Juliette Reinders Folmer][@jrfnl] for the patch
65
+
- Fixed bug [#652] : Generic.NamingConventions.ConstructorName: false positives for PHP-4 style calls to PHP-4 style parent constructor when a method with the same name as the parent class was called on another class.
66
+
- Thanks to [Juliette Reinders Folmer][@jrfnl] for the patch
67
+
- Fixed bug [#652] : Generic.NamingConventions.ConstructorName: false negatives for PHP-4 style calls to parent constructor for function calls with whitespace and comments in unconventional places.
68
+
- Thanks to [Juliette Reinders Folmer][@jrfnl] for the patch
69
+
- Fixed bug [#653] : Generic.Classes.DuplicateClassName : the sniff did not skip namespace keywords used as operators, which could lead to false positives.
70
+
- Thanks to [Juliette Reinders Folmer][@jrfnl] for the patch
71
+
- Fixed bug [#653] : Generic.Classes.DuplicateClassName : sniff going into an infinite loop during live coding.
72
+
- Thanks to [Juliette Reinders Folmer][@jrfnl] for the patch
73
+
- Fixed bug [#653] : Generic.Classes.DuplicateClassName : false positives/negatives when a namespace declaration contained whitespace or comments in unconventional places.
74
+
- Thanks to [Juliette Reinders Folmer][@jrfnl] for the patch
75
+
- Fixed bug [#653] : Generic.Classes.DuplicateClassName : namespace for a file going in/out of PHP was not remembered/applied correctly.
76
+
- Thanks to [Juliette Reinders Folmer][@jrfnl] for the patch
0 commit comments