1.2.1219. Trailing Comma In Calls¶
The last argument may be left empty.
This feature was introduced in PHP 7.3.
<?php
// VCS friendly call
// PHP 7.3 and more recent
foo(1,
2,
3,
);
// backward compatible call
// All PHP versions
foo(1,
2,
3
);
?>
See also PHP RFC: Allow a trailing comma in function calls.
1.2.1219.1. Connex PHP features¶
1.2.1219.1.1. Specs¶
Short name |
Php/TrailingComma |
Rulesets |
All, Appinfo, CE, Changed Behavior, CompatibilityPHP53, CompatibilityPHP54, CompatibilityPHP55, CompatibilityPHP56, CompatibilityPHP70, CompatibilityPHP71, CompatibilityPHP72 |
Exakat since |
1.4.0 |
PHP Version |
All |
Severity |
Minor |
Time To Fix |
Quick (30 mins) |
Precision |
Very high |
Available in |