3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php class Test { public function returnSomething(){ return null; } } $obj = new Test; var_dump(null === $ob->returnSomething());
Output for 7.0.5 - 7.2.0
Notice: Undefined variable: ob in /in/lQlEk on line 10 Fatal error: Uncaught Error: Call to a member function returnSomething() on null in /in/lQlEk:10 Stack trace: #0 {main} thrown in /in/lQlEk on line 10
Process exited with code 255.
Output for 7.0.0 - 7.0.4
Notice: Undefined variable: ob in /in/lQlEk on line 10 Fatal error: Uncaught Error: Call to a member function returnSomething() on unknown in /in/lQlEk:10 Stack trace: #0 {main} thrown in /in/lQlEk on line 10
Process exited with code 255.
Output for 5.6.8 - 5.6.28
Notice: Undefined variable: ob in /in/lQlEk on line 10 Fatal error: Call to a member function returnSomething() on null in /in/lQlEk on line 10
Process exited with code 255.
Output for 5.3.21 - 5.5.35
Notice: Undefined variable: ob in /in/lQlEk on line 10 Fatal error: Call to a member function returnSomething() on a non-object in /in/lQlEk on line 10
Process exited with code 255.