3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?hh interface Foo { public function foo(String $foo) : String; } class Bar implements Foo { public function foo(String $foo) { return [$foo]; } } $b = new Bar; var_dump($b->foo("test"));
Output for hhvm-3.10.0 - 3.12.0
array(1) { [0]=> string(4) "test" }
Output for 5.3.0 - 5.4.32
<?hh interface Foo { public function foo(String $foo) : String; } class Bar implements Foo { public function foo(String $foo) { return [$foo]; } } $b = new Bar; var_dump($b->foo("test"));