3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php class Test { public function getDataType($value) { switch($value) { case is_bool($value): return 'bool'; case is_null($value): return null; case is_integer($value): return 'int'; default: return 'str'; } } } Test::getDataType(true);
Output for 7.0.0 - 7.2.0
Deprecated: Non-static method Test::getDataType() should not be called statically in /in/SEcur on line 20
Output for 5.3.18 - 5.6.28
Strict Standards: Non-static method Test::getDataType() should not be called statically in /in/SEcur on line 20