From 418fc360ec2b1357e9e1dc4913b119d26c6e08df Mon Sep 17 00:00:00 2001 From: Peter Stephenson Date: Sat, 19 Sep 2009 16:29:16 +0000 Subject: Darel Henman: users/14412: fix confusion in getopts documentation --- Doc/Zsh/builtins.yo | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Doc/Zsh/builtins.yo') diff --git a/Doc/Zsh/builtins.yo b/Doc/Zsh/builtins.yo index b93257058..5ca4ae612 100644 --- a/Doc/Zsh/builtins.yo +++ b/Doc/Zsh/builtins.yo @@ -671,7 +671,7 @@ a `tt(PLUS())' or a `tt(-)', or the argument `tt(-)tt(-)', ends the options. Note that a single `tt(-)' is not considered a valid option argument. var(optstring) contains the letters that tt(getopts) recognizes. If a letter is followed by a `tt(:)', that option -is expected to have an argument. The options can be +requires an argument. The options can be separated from the argument by blanks. Each time it is invoked, tt(getopts) places the option letter it finds @@ -692,7 +692,7 @@ stored. The option itself is still stored in var(name) in this case. A leading `tt(:)' in var(optstring) causes tt(getopts) to store the letter of any invalid option in tt(OPTARG), and to set var(name) to -`tt(?)' for an unknown option and to `tt(:)' when a required option is +`tt(?)' for an unknown option and to `tt(:)' when a required argument is missing. Otherwise, tt(getopts) sets var(name) to `tt(?)' and prints an error message when an option is invalid. The exit status is nonzero when there are no more options. -- cgit 1.4.1