3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php class Bar { } class Foo { public function getBar(int $teste) { var_dump($teste); } } $foo = new Foo(); var_dump($foo->getBar(50));
based on qQDsW
Output for 7.0.0 - 7.2.0
int(50) NULL
Output for 5.3.18 - 5.6.28
Catchable fatal error: Argument 1 passed to Foo::getBar() must be an instance of int, integer given, called in /in/ZQ2qC on line 17 and defined in /in/ZQ2qC on line 9
Process exited with code 255.