Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: [PATCH] Fix crash on unset-through-nameref
On Mon, Mar 4, 2024 at 11:36 AM Stephane Chazelas <stephane@xxxxxxxxxxxx> wrote:
>
> The other one is now wrong in a different way:
>
> $ ./Src/zsh -c 'f() { typeset -n v=$1; unset v; typeset -p w; v=(a b); }; w=1; f w; typeset -p w'
> typeset -a w=( a b )
> $ ./Src/zsh -c 'f() { typeset -n v=$1; unset v; typeset -p w; v=(a b); }; v=1; w=1; f w; typeset -p w'
> $
Src/zsh -c 'f() { typeset -n v=$1; unset v; typeset -p w; v=(a b) ||
echo failed; }; v=1; w=1; f w; typeset -p w'
failed
So removing the PM_DECLARED is hiding the "attempt to assign array
value to non-array" message but still not permitting the assignment.
This probably is not better than the previous situation.
Messages sorted by:
Reverse Date,
Date,
Thread,
Author