This code triggers the rule php:S1788 'Method arguments with default value should be last':
public function __construct($name, $attributes = array(), ...$children) {
The method signature combines an argument with a default value, $attributes, with an argument with variable number of values, $children.
Defining it this way allows a flexible way to call it with 1, 2, 3 or more arguments.
The $children argument has to be the last argument because it captures all values passed after the first 2. This makes it impossible to move the $attributes argument after $children.
It would be nice if this situation could be detected and not treat it as a violation of the php:S1788 rule.
rob schlüter