3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php class foobar { private $bar = "blah</br>\n"; public foo() { echo $this->$bar; } } foobar::foo(); $f = new foobar(); $f->foo();
Output for 5.4.0 - 5.4.19
Parse error: syntax error, unexpected 'foo' (T_STRING), expecting variable (T_VARIABLE) in /in/esFqO on line 7
Process exited with code 255.
Output for 5.3.0 - 5.3.27
Parse error: syntax error, unexpected T_STRING, expecting T_VARIABLE in /in/esFqO on line 7
Process exited with code 255.