diff options
-rw-r--r-- | ChangeLog | 4 | ||||
-rw-r--r-- | Doc/Zsh/compsys.yo | 7 | ||||
-rw-r--r-- | Src/Zle/computil.c | 2 |
3 files changed, 11 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog index f890b788d..793f2f9e8 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,9 @@ 2002-02-18 Sven Wischnowsky <wischnow@zsh.org> + * 16669: Doc/Zsh/compsys.yo, Src/Zle/computil.c: allow an + argument containing only a single colon as a separator between + options to _arguments and specs + * 16668: Src/Zle/compcore.c: fix group handling nothing should now possibly be added to the wrong group again diff --git a/Doc/Zsh/compsys.yo b/Doc/Zsh/compsys.yo index 16eff6f77..73ada9ba2 100644 --- a/Doc/Zsh/compsys.yo +++ b/Doc/Zsh/compsys.yo @@ -2996,12 +2996,15 @@ Like tt(_tags) this function supports the tt(-C) option to give a different name for the argument context field. ) findex(_arguments) -item(tt(_arguments) [ tt(-ACS) ] [ tt(-O) var(name) ] [ tt(-M) var(matchspec) ] var(spec) ...)( +item(tt(_arguments) [ tt(-ACS) ] [ tt(-O) var(name) ] [ tt(-M) var(matchspec) ] [ tt(:) ] var(spec) ...)( This function can be used to complete words on the line by describing the options and arguments which may be passed to the command for which completion is being performed. The description is given as arguments to this function, with each var(spec) describing one option or normal -argument of the command. The forms of var(spec) understood are: +argument of the command. To separate these var(spec)s from the +options given to tt(_arguments) itself, they can be preceeded by an +argument containing a single colon. The forms of var(spec) +understood are: startitem() xitem(var(n)tt(:)var(message)tt(:)var(action)) diff --git a/Src/Zle/computil.c b/Src/Zle/computil.c index ae94bdf57..b5610fb77 100644 --- a/Src/Zle/computil.c +++ b/Src/Zle/computil.c @@ -1065,6 +1065,8 @@ parse_cadef(char *nam, char **args) args++; } + if (*args && !strcmp(*args, ":")) + args++; if (!*args) return NULL; |