3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $a = 1; var_dump((unset) ($a)); var_dump($a); $x = new StdClass; $x->stuff = 'foo'; var_dump(property_exists($x, "stuff")); var_dump($x->stuff); (unset)$x->stuff; var_dump(property_exists($x, "stuff")); var_dump($x->stuff);
based on TKh9N
Output for 7.2.0
Deprecated: The (unset) cast is deprecated in /in/Bedia on line 4 Deprecated: The (unset) cast is deprecated in /in/Bedia on line 12 NULL int(1) bool(true) string(3) "foo" bool(true) string(3) "foo"
Output for 5.3.19 - 7.1.10
NULL int(1) bool(true) string(3) "foo" bool(true) string(3) "foo"