3v4l.org

run code in 300+ PHP versions simultaneously
<?php echo "\$a unset\n isset: "; var_export(isset($a)); echo "\n value: "; var_export($a); echo "\n\n"; $a = null; echo "\$a is null\n isset: "; var_export(isset($a)); echo "\n value: "; var_export($a); echo "\n\n"; $a = (object) null; echo "\$a is object\n isset: "; var_export(isset($a)); echo "\n value: "; var_export($a); echo "\n\n"; echo "\$a->b unset:\n isset: "; var_export(isset($a->b)); echo "\n value: "; var_export($a->b); echo "\n\n"; $a->b = null; echo "\$a->b is null:\n isset: "; var_export(isset($a->b)); echo "\n value: "; var_export($a->b); echo "\n\n"; echo "\$a->b is null, what's \$a?\n isset: "; var_export(isset($a)); echo "\n value: "; var_export($a); echo "\n";
Output for git.master, git.master_jit, rfc.property-hooks
$a unset isset: false value: Warning: Undefined variable $a in /in/ngRNN on line 5 NULL $a is null isset: false value: NULL $a is object isset: true value: (object) array( ) $a->b unset: isset: false value: Warning: Undefined property: stdClass::$b in /in/ngRNN on line 23 NULL $a->b is null: isset: false value: NULL $a->b is null, what's $a? isset: true value: (object) array( 'b' => NULL, )

This tab shows result from various feature-branches currently under review by the php developers. Contact me to have additional branches featured.

Active branches

Archived branches

Once feature-branches are merged or declined, they are no longer available. Their functionality (when merged) can be viewed from the main output page


preferences:
35.85 ms | 406 KiB | 5 Q