Open tcovert opened 7 years ago
Confirmed. The docstring says: "Create a new NamedTuple with the new value set on it, either overwriting the old value or appending a new value." But the implementation uses merge
which (as documented) takes the LHS. It would make sense to use the RHS instead since that's how merge
works in general, and how NamedTuple
is going to be implemented in Base. Also setindex
isn't very useful if it doesn't overwrite existing values.
I would have thought the result would be
(a = 1, b = "cde")