From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29391 invoked from network); 4 Feb 2000 09:43:23 -0000 Received: from sunsite.auc.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 4 Feb 2000 09:43:23 -0000 Received: (qmail 28781 invoked by alias); 4 Feb 2000 09:43:13 -0000 Mailing-List: contact zsh-workers-help@sunsite.auc.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 9559 Received: (qmail 28773 invoked from network); 4 Feb 2000 09:43:13 -0000 Date: Fri, 4 Feb 2000 10:43:11 +0100 (MET) Message-Id: <200002040943.KAA22559@beta.informatik.hu-berlin.de> From: Sven Wischnowsky To: zsh-workers@sunsite.auc.dk In-reply-to: Alexandre Duret-Lutz's message of 04 Feb 2000 10:30:39 +0100 Subject: Re: flex - Alexandre Duret-Lutz wrote: > >>> "Tanaka" == Tanaka Akira writes: > > Tanaka> Z(2):akr@is27e1u11% Src/zsh -f > Tanaka> is27e1u11% bindkey -e; autoload -U compinit; compinit -D; compdef _tst tst > Tanaka> is27e1u11% flex - > Tanaka> - -- generate C++ scanner class > Tanaka> -7 -- generate 7-bit scanner > Tanaka> ... > > Tanaka> The option `+' isn't displayed. > > I think this is since 9216. The character just after `-' in an argument > definition was not checked before, but now it is. And since `+' has a > special meaning for _arguments, perhaps the cleaner way to correct this is > to escape it. I think we better document this. Bye Sven diff -ru ../z.old/Doc/Zsh/compsys.yo Doc/Zsh/compsys.yo --- ../z.old/Doc/Zsh/compsys.yo Fri Feb 4 09:53:48 2000 +++ Doc/Zsh/compsys.yo Fri Feb 4 10:42:17 2000 @@ -2084,7 +2084,10 @@ and no other argument specification may be given after it. In the simplest form the var(opt-spec) is just the option name -beginning with a minus or a plus sign, such as `tt(-foo)'. In this +beginning with a minus or a plus sign, such as `tt(-foo)'. If the +command accepts the option both with a leading minus and a plus sign, +one can use either tt(-+foo) or tt(+-foo) to define both options at +once. In this case, the first argument for the option (if any) has to come as a separate word directly after the option and the option may appear only once on the line (and if it is already on the line, the option name @@ -2097,6 +2100,10 @@ instead. If the argument may be given as the next string or in same string as the option name but separated from it by an equal sign, a `tt(=)' should be used instead of the minus or plus sign. + +Note that this and the shortcut syntax with a leading tt(-+) or tt(+-) +means that for options like tt(-+) the second character has to be +quoted with a backslash. If the option may be given more than once, a star (`tt(*)') has to be added in front of the var(opt-spec). -- Sven Wischnowsky wischnow@informatik.hu-berlin.de