3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php if ($doesNotEsit ?? false && false) { var_dump(1); // ok we don't go here } $doesExist = true; if ($doesExist ?? false && false) { var_dump('2'); // AILLE, we go here } $doesExist = true; if (($doesExist ?? false) && false) { var_dump('3'); // Ok, we are safe now }
Output for hhvm-3.18.5 - 3.22.0, 7.1.0 - 7.2.6
string(1) "2"
Output for 5.6.0 - 5.6.30
Parse error: syntax error, unexpected '?' in /in/ouumr on line 4
Process exited with code 255.