public
|
__construct(
Expr $expr,
Expr $valueVar,
array{keyVar?:(Expr|null), byRef?:bool, stmts?:Stmt[]} $subNodes = [],
array<string, mixed> $attributes = [],
)
Constructs a foreach node.
Constructs a foreach node.
Parameters
$expr |
Expression to iterate
|
$valueVar |
Variable to assign value to
|
$subNodes |
Array of the following optional subnodes:
'keyVar' => null : Variable to assign key to
'byRef' => false : Whether to assign value by reference
'stmts' => array(): Statements
|
$attributes |
Additional attributes
|
Overrides
|
#
|