Zsh Mailing List Archive
Messages sorted by:
_arguments -n / $NORMARG (was: Re: [PATCH 1/2] __arguments: New completion function for _arguments.)
- X-seq: zsh-workers 48372
- From: Daniel Shahaf <d.s@xxxxxxxxxxxxxxxxxx>
- To: Zsh workers <zsh-workers@xxxxxxx>
- Subject: _arguments -n / $NORMARG (was: Re: [PATCH 1/2] __arguments: New completion function for _arguments.)
- Date: Thu, 1 Apr 2021 22:34:07 +0000
- Archived-at: <https://zsh.org/workers/48372>
- Archived-at: <http://www.zsh.org/sympa/arcsearch_id/zsh-workers/2021-04/20210401223407.GG11180%40tarpaulin.shahaf.local2>
- In-reply-to: <20210401173305.GB11180@tarpaulin.shahaf.local2>
- List-id: <zsh-workers.zsh.org>
- References: <firstname.lastname@example.org> <96182-1617281582.024669@4LIl.h-KW.lXZv> <20210401173305.GB11180@tarpaulin.shahaf.local2>
Daniel Shahaf wrote on Thu, Apr 01, 2021 at 17:33:05 +0000:
> Oliver Kiddle wrote on Thu, Apr 01, 2021 at 14:53:02 +0200:
> > You wrote:
> > > + '-n[set $NORMARG]' \
> > -n should not be used, it is fundamentally broken and will never be
> > fixed because the right answer to $NORMARG as it is defined can be a
> > list of possibilities. It grabs an internal variable from the first
> > element of a linked-list and dumps it out. The problem it was added to
> > solve would have had better solutions.
> > Could hide it with ! or add a comment.
> I'll add !, and we should document that in the manual too if it isn't
The manual doesn't already include such a warning, but I don't
understand how exactly $NORMARG is broken, so I can't document that.
Could you elaborate on what cases «_arguments -n», as implemented, would
cause breakage in?
The comment above the definition of the linked list's type (struct
castate) says the list comprises one node per set. Does that refer to
_arguments option sets? If so, perhaps -n is fine to use so long as
option sets aren't also used?
Messages sorted by: