3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $c = new c(); var_dump(isset($c->a)); // no problem var_dump(isset($c->a->b)); // undefined index: a var_dump(isset($c->b->c)); // undefined index: b var_dump(isset($c->d['e'])); // undefined index: d class c { public $x = array(); public function __get($name) { return $this->__isset($name) ? $this->x[$name] : null; } public function __isset($name) { return isset($this->x[$name]); } } ?>
Output for 5.0.0 - 5.6.21, hhvm-3.12.0, 7.0.0 - 7.1.0
bool(false) bool(false) bool(false) bool(false)
Output for hhvm-3.10.0

Process exited with code 153.
Output for 4.4.2 - 4.4.9
Parse error: syntax error, unexpected T_STRING, expecting T_OLD_FUNCTION or T_FUNCTION or T_VAR or '}' in /in/IDfeo on line 10
Process exited with code 255.
Output for 4.3.0 - 4.3.1, 4.3.5 - 4.4.1
Parse error: parse error, unexpected T_STRING, expecting T_OLD_FUNCTION or T_FUNCTION or T_VAR or '}' in /in/IDfeo on line 10
Process exited with code 255.
Output for 4.3.2 - 4.3.4
Parse error: parse error, expecting `T_OLD_FUNCTION' or `T_FUNCTION' or `T_VAR' or `'}'' in /in/IDfeo on line 10
Process exited with code 255.