Destructuring of NamedTuple in julia 1.10

I wonder if there is a way to destructure a namedtuple with splatting like this

(; a, nt...) = (; a=1, b=2, c=3)

where one is expecting to get a = 1 and nt = (; b=2, c=3) setted
This forms fails @ home with julia v1.10 and history.md does not mention any change

Currently those forms work to compute the result

Base.structdiff((; a=1, b=2, c=3), NamedTuple{(:a,)})
Base.structdiff((; a=1, b=2, c=3), (; a=nothing))

but curiously not this one

Base.structdiff((; a=1, b=2, c=3), (:a,))

SEE ALSO

try this way

 a, nt... = (; a=1, b=2, c=3)

I wonder why in the third case we get a result similar to the first and not the second

julia>  f, nt... = (; a=1, b=2, c=3)
(a = 1, b = 2, c = 3)

julia> f
1

julia> nt
(b = 2, c = 3)

julia>  f, nt... = [(; a=1, b=2, c=3)...,]
3-element Vector{Int64}:
 1
 2
 3

julia> f
1

julia> 

julia> nt
2-element Vector{Int64}:
 2
 3

julia>  f, nt... = ((; a=1, b=2, c=3)...,)
(1, 2, 3)

julia> f
1

julia> nt
(b = 2, c = 3)

OK for a, nt... = (; a=1, b=2, c=3)

In the frontend everything is driven by tuple when you destructure. so that catches too an inner namedtuple

After the lowering, everything tends to be array/vector-oriented.
When you splat out inside a container, it will iterate / collect silently
The two cases you point out is the default case there since a namedtuple iterates on value

@assert (; a=1, b=2, c=3) |> collect == [1, 2, 3]

So we’ve got a solution, but it’s a bit tricky and inconsistent. Half of a bug

The parser/lowerer may handle this case better. But what about

f, nt... = identity(((; a=1, b=2, c=3)...,)) or
f, nt... = ((; a=1, b=2, c=3)...,) |> identity
f, nt... = ((; a=1, b=2, c=3)...,) |> myident

There must be a frontier. Moreover The scheme & julia code there is very hard to maintain / onboard / evolve.
It’s well known Scheme is a famous prankster when it’s about lisping on S

SEE