3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php /* class Foo { public static function barStatic() { } public function bar() { } } $foo = new Foo(); var_dump(is_callable(array($foo, 'bar'))); var_dump(is_callable(array($foo, 'barStatic'))); var_dump(is_callable(array('Foo', 'bar'))); var_dump(is_callable(array('Foo', 'barStatic'))); var_dump(is_callable('Foo::bar')); var_dump(is_callable('Foo::barStatic')); */ var_dump(is_callable('ReflectionMethod::setAccessible')); var_dump(is_callable(array('ReflectionMethod', 'setAccessible'));
Output for 5.3.0 - 5.4.30
Parse error: syntax error, unexpected ';' in /in/dZ9DZ on line 26
Process exited with code 255.