3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $v = 18; function f( &$p ) { $p = 36; return $p; } echo call_user_func('f', $v); // error: expecting reference variable
Output for 7.1.0
Warning: Parameter 1 to f() expected to be a reference, value given in /in/Ba7qZ on line 7 36
Output for 5.3.0 - 5.6.28, 7.0.0 - 7.0.14
Warning: Parameter 1 to f() expected to be a reference, value given in /in/Ba7qZ on line 7
Output for 4.3.0 - 5.0.5, 5.1.1 - 5.2.17, hhvm-3.10.0 - 3.12.0
36
Output for 5.1.0
Fatal error: fatal flex scanner internal error--end of buffer missed in /in/Ba7qZ on line 7
Process exited with code 255.