Destructuring copied values, so normalising an array in place still needed a temporary variable and a loop that reads worse than the operation it performs.
$pair = [1, 2];
[&$a, &$b] = $pair;
$a = 9;
// $pair is now [9, 2]
foreach ($rows as [&$sku, $price]) {
$sku = strtoupper($sku);
}
unset($sku);
The unset after the loop is not optional and is the same advice as for any reference in a foreach: leave it bound and the next loop reusing that variable name overwrites the last element, which is the single most durable PHP gotcha. The legitimate use is in-place normalisation of a large array where the copy is the expensive part; everywhere else the copying version is clearer and the cost is not measurable.