3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php abstract class foo { abstract public function &bar(): string; } class herp extends foo { public string $member = 'derp'; public function bar(): string { return $this->member; } }
Output for 7.0.0 - 7.0.2
Parse error: syntax error, unexpected 'string' (T_STRING), expecting variable (T_VARIABLE) in /in/aupo5 on line 8
Process exited with code 255.
Output for 5.3.22 - 5.6.17
Parse error: syntax error, unexpected ':', expecting ';' or '{' in /in/aupo5 on line 4
Process exited with code 255.