3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php function foo() { return null; } if (empty($path = foo())) { echo 'it works'; } else { echo 'it fails'; }
Output for 5.5.24 - 5.6.28, hhvm-3.10.0 - 3.12.0, 7.0.0 - 7.1.0
it works
Output for 5.3.7 - 5.4.45
Parse error: syntax error, unexpected '=', expecting ')' in /in/Se7cd on line 7
Process exited with code 255.