Arrays often repeat the same word twice, once as the key and once as the variable: ['x' => $x, 'y' => $y]. Weilin Du's RFC adds =$name as a shorthand for 'name' => $name, so the key comes straight from the variable's name. It targets PHP 8.7.

What changes

The shorthand works when you build an array and when you pull one apart:

$x = 10;
$y = 20;

$point = [=$x, =$y]; // $point = ['x' => $x, 'y' => $y]
[=$x, =$y] = $point; // ['x' => $x, 'y' => $y] = $point

You can mix it with regular keys, and it works in foreach destructuring too:

$name = 'Weilin';
$age = 26;
$user = ['id' => 1, =$name, =$age];
// ['id' => 1, 'name' => 'Weilin', 'age' => 26]

$rows = [['name' => 'Weilin']];
foreach ($rows as [=$name]) {
    echo $name; // Weilin
}

The long forms get it as well, so array(=$name) and list(=$name) = $user both work. The key keeps the variable's exact case, so =$Name gives you a 'Name' key.

Only a plain variable qualifies. =$$name, =$name[0] and =$object->name are all invalid, and for those you write the key out yourself. Function calls are out of scope, so foo(=$name) doesn't work either.

The first draft used :$name. The RFC switched to = because : already shows up inside arrays as part of a ternary, as in [$condition ? 'bar' :$baz].

What it means for existing code

Nothing breaks. The syntax is invalid today, so no current code can mean anything else by it. Static analyzers and IDEs will need to learn the new element form in [], array() and list().

Where it stands

Weilin Du announced the RFC on the internals list on September 29, 2026, and revised it the same day to use = and to cover array() and list(). The author calls it an early stage proposal, and there's no implementation yet. A vote would need a two-thirds majority.