3v4l.org

run code in 300+ PHP versions simultaneously
<?php $q = array(); $x=0; function a(){ global $q; $q[]="a() was called"; return 1; } function &b(){ global $q; global $x; $q[]="b() was called"; return $x; } echo a()+ ++b(); echo implode(",", $q);
Output for 5.3.0 - 5.3.21, 5.4.0 - 5.4.11
Fatal error: Can't use function return value in write context in 6W6RY on line 15
Process exited with code 255.

preferences:
198.58 ms | 1395 KiB | 41 Q