Clarification on section 2.6 trailing commas
Closed this issue · 1 comments
Hello!
I am working on a PHPCS ruleset based on this standard and need some clarification to be sure I am implementing it all correctly.
The section 2.6 states Numerous PHP constructs
.
Does this include all of the currently available constructs or only the ones specifically listed in the examples?
If any new such constructs are added in the future to PHP, does this section automatically apply to them?
Do you have a definitive list of constructs that this covers?
Thanks in advance!
Does this include all of the currently available constructs or only the ones specifically listed in the examples?
As a rule, examples are only examples in all the PSR/PER. These are not rules or constraints. You should pay attention to what's written in text.
So the answer is "all of the currently available constructs".
If any new such constructs are added in the future to PHP, does this section automatically apply to them?
Yes.
Do you have a definitive list of constructs that this covers?
No.