3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php class C implements ArrayAccess { public function offsetExists ( $offset ) { echo $offsetExists; } public function offsetGet ( $offset ) { echo $offsetGet; } public function offsetSet ( $offset , $value ) { echo $offsetSet; } public function offsetUnset ( $offset ) { echo $offsetUnset; } } } $x = new C(); var_dump(empty($x));
Output for 5.3.0 - 5.4.20
Parse error: syntax error, unexpected '}' in /in/2pkEn on line 10
Process exited with code 255.