Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Weird error: opts[(r)-e]: parameter not set
- X-seq: zsh-users 22043
- From: Sebastian Gniazdowski <psprint@xxxxxxxxxxxx>
- To: zsh-users@xxxxxxx
- Subject: Weird error: opts[(r)-e]: parameter not set
- Date: Sat, 29 Oct 2016 07:14:38 -0700
- Dkim-signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=fastmail.com; h= content-transfer-encoding:content-type:date:from:message-id :mime-version:subject:to:x-me-sender:x-me-sender:x-sasl-enc :x-sasl-enc; s=mesmtp; bh=QXeu9f9L9eu55EZ8kRNgwQ+zpCI=; b=gyCSEF xtCju4qzl93i4IrCZFHXtUkGYofkyI8ZSn3GDvjWys3aToCHjJFmHqCREfgK8bU+ 6keQwJQZpu45mP0/mHZRuV0IDAhSZII0Da+4kEDMc1Xq1WSfsysG+bnR3Ug3tFoa 2Z6GGyLpZduPHDeIVqGGskXt95+A+LgXJdTLE=
- Dkim-signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=content-transfer-encoding:content-type :date:from:message-id:mime-version:subject:to:x-me-sender :x-me-sender:x-sasl-enc:x-sasl-enc; s=smtpout; bh=QXeu9f9L9eu55E Z8kRNgwQ+zpCI=; b=BBQi5Y7UEng+ms2HwVtVBQzdWn/BdfETFdTPPkrGeXa1bq qPprjhy1HOS1skSR6Dscz06AiiFoSJQXLP6NWsN86G/8mnjYJz+Oe/MypoQer837 RXFyAuy8rLAq6BKI8b/gPxocA5hSnJ/LfcuiQrhld7pAYoQSn6YUu1oRfP9fg=
- List-help: <mailto:zsh-users-help@zsh.org>
- List-id: Zsh Users List <zsh-users.zsh.org>
- List-post: <mailto:zsh-users@zsh.org>
- Mailing-list: contact zsh-users-help@xxxxxxx; run by ezmlm
Hello,
I do:
local -a opts
zparseopts -a opts -D ${(s::):-eLdgabsTtm}
if [[ "${#opts[@]}" -eq 0 || ( "${#opts[@]}" -eq 1 &&
"${opts[(r)-e]}" = "-e" ) ]]; then
and this at one user setup results in error:
functionname:12: opts[(r)-e]: parameter not set
Line number points to the if. Having set -u is capable of generating
such error, however not in this case, as there is `local -a opts`. What
else can do this?
--
Sebastian Gniazdowski
psprint@xxxxxxxxxxxx
Messages sorted by:
Reverse Date,
Date,
Thread,
Author