3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php class foo { } function a($input) { $input->bar = 'a'; } function b($input) { $input->bar = 'b'; } $stuff = new Input(); a($stuff); b($stuff); var_dump($stuff);
Output for 7.0.0 - 7.1.0
Fatal error: Uncaught Error: Class 'Input' not found in /in/eQ0O9:17 Stack trace: #0 {main} thrown in /in/eQ0O9 on line 17
Process exited with code 255.
Output for 5.2.15 - 5.6.28
Fatal error: Class 'Input' not found in /in/eQ0O9 on line 17
Process exited with code 255.