You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
Copying an array using the ... operator is different from copying via assignment because the array pointer is maintained in the second case. It would be great if there would be a mutator which switches one for the other.
Describe the solution you'd like
$array = [1, 2, 3];
$array2 = [...$array]; // -> this could be mutated to $array2 = $array;
Hello!
Is your feature request related to a problem? Please describe.
Copying an array using the
...
operator is different from copying via assignment because the array pointer is maintained in the second case. It would be great if there would be a mutator which switches one for the other.Describe the solution you'd like
Additional context
See example here, I hope this clarifies what I mean: https://3v4l.org/gfW5D#v8.0.8
I noticed there is already a Spread Mutator so I thought this could be something similar to that one, let me know if this makes sense.
The text was updated successfully, but these errors were encountered: