3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php class Foo { private $bar = 'baz'; } class Qwe extends Foo { public function qwerty() { $reader = function & ($object, $property) { $value = & Closure::bind(function & () use ($property) { return $this->$property; }, $object, $object)->__invoke(); return $value; }; $bar = & $reader($this, 'bar'); var_dump($bar); } } new Qwe()->qwerty();
Output for 5.4.0 - 5.4.17
Parse error: syntax error, unexpected '->' (T_OBJECT_OPERATOR) in /in/JqRO9 on line 29
Process exited with code 255.
Output for 5.3.0 - 5.3.27
Parse error: syntax error, unexpected T_OBJECT_OPERATOR in /in/JqRO9 on line 29
Process exited with code 255.