Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: [PATCH] zed fails with setopt nounset unless option -x is given
On Fri, May 20, 2022 at 7:18 AM Peter Stephenson
<p.w.stephenson@xxxxxxxxxxxx> wrote:
>
> Looks straightforward.
>
> +if [[ $+opts[-x] == 1 && $opts[-x] == <-> ]]; then
This actually points out a potential issue with nounset in general:
There's no way to pre-declare an associative array key (or even a
normal array element) to prevent this from happening, the way one can
use typeset to declare a scalar.
Messages sorted by:
Reverse Date,
Date,
Thread,
Author