<?php
$z = array();
list($a $b $c) = array(1, 2, 3);
list($z[], $z[], $z[]) = array(1, 2, 3);
var_dump($a, $b, $c)
var_dump($z);
- Output for 7.0.0 - 7.0.2
- Parse error: syntax error, unexpected '$b' (T_VARIABLE), expecting :: (T_PAAMAYIM_NEKUDOTAYIM) in /in/ROJ7Y on line 4
Process exited with code 255. - Output for 5.5.24 - 5.5.31, 5.6.8 - 5.6.17
- Parse error: syntax error, unexpected '$b' (T_VARIABLE), expecting ',' or ')' in /in/ROJ7Y on line 4
Process exited with code 255.
preferences:
164.27 ms | 1395 KiB | 28 Q