3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php class Foo { } class Bar extends Foo { public function __construct() { $foo = new Foo(); var_dump($foo); deleteMe($foo); //gc_collect_cycles(); var_dump($foo); } } static function deleteMe(&$obj) { $obj = (unset) $obj; } $bar = new Bar();
Output for 5.4.0 - 5.5.10
Parse error: syntax error, unexpected 'deleteMe' (T_STRING), expecting '(' in /in/Jrt6I on line 22
Process exited with code 255.
Output for 5.3.0 - 5.3.28
Parse error: syntax error, unexpected T_FUNCTION, expecting T_PAAMAYIM_NEKUDOTAYIM in /in/Jrt6I on line 22
Process exited with code 255.