3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php class Foo { private $a = stdClass(); function bar() { return $this->a; } } $foo = new Foo(); $b = $foo->bar(); $b->beep = 'boop'; $c = $foo->bar(); var_dump($c);
Output for 5.3.0 - 5.4.28
Parse error: syntax error, unexpected '(', expecting ',' or ';' in /in/vP330 on line 4
Process exited with code 255.