3v4l.org

run code in 200+ php & hhvm versions
Bugs & Features
<?php $a = ['var1' => 'foo', 'var2' => 'bar']; list($var1, $var2) = $a; var_dump($var1, $var2);

Shows result from various feature-branches currently under review from the php developers. Contact me to have additional branches featured.

Output for Typed properties v2
Notice: Undefined offset: 0 in /in/B2pvV on line 4 Notice: Undefined offset: 1 in /in/B2pvV on line 4 NULL NULL
Output for Arrow functions
Notice: Undefined offset: 0 in /in/B2pvV on line 4 Notice: Undefined offset: 1 in /in/B2pvV on line 4 NULL NULL
Output for Object typehint
Notice: Undefined offset: 0 in /in/B2pvV on line 4 Notice: Undefined offset: 1 in /in/B2pvV on line 4 NULL NULL
Output for Array change keys
Notice: Undefined offset: 0 in /in/B2pvV on line 4 Notice: Undefined offset: 1 in /in/B2pvV on line 4 NULL NULL
Output for Lexical anon
Notice: Undefined offset: 0 in /in/B2pvV on line 4 Notice: Undefined offset: 1 in /in/B2pvV on line 4 NULL NULL

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