3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php class Foo {} $foo = new Foo(new Bar()); print_r($foo);
Output for 7.1.0
Fatal error: Uncaught Error: Class 'Bar' not found in /in/Ivgv4:5 Stack trace: #0 {main} thrown in /in/Ivgv4 on line 5
Process exited with code 255.
Output for 5.0.0 - 5.6.28, 7.0.0 - 7.0.14
Foo Object ( )
Output for hhvm-3.12.0
Fatal error: Class undefined: Bar in /in/Ivgv4 on line 5
Process exited with code 255.
Output for hhvm-3.10.0

Process exited with code 153.
Output for 4.3.0 - 4.4.9
foo Object ( )