3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php class Faz {} class Baz extends Faz { } incerface Foo { public function du(Faz $param); } class Boo implements Foo { public funccion du(Baz $param) { echo false; } } $c = new Boo(); $c->du(new Baz());
Output for 5.4.0 - 5.4.15
Parse error: syntax error, unexpected 'Foo' (T_STRING) in /in/L9c32 on line 8
Process exited with code 255.
Output for 5.3.0 - 5.3.25
Parse error: syntax error, unexpected T_STRING in /in/L9c32 on line 8
Process exited with code 255.