3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php /*function ref(&$a) {} function val($a) {}*/ $b = []; $a = $b['a']['b']; $a =& $b['a']['b']; ref($b['a']['b']); val($b['a']['b']);
based on d65QF
Output for 7.0.0 - 7.2.0
Notice: Undefined index: a in /in/WcD4K on line 7 Fatal error: Uncaught Error: Call to undefined function ref() in /in/WcD4K:9 Stack trace: #0 {main} thrown in /in/WcD4K on line 9
Process exited with code 255.
Output for 5.4.11 - 5.6.28
Notice: Undefined index: a in /in/WcD4K on line 7 Fatal error: Call to undefined function ref() in /in/WcD4K on line 9
Process exited with code 255.
Output for 5.3.21 - 5.3.29
Parse error: syntax error, unexpected '[' in /in/WcD4K on line 6
Process exited with code 255.