This is the mail archive of the
cygwin@sourceware.cygnus.com
mailing list for the Cygwin project.
Re: bash-2.x
- To: jan at digicash dot com, hanwen at cs dot uu dot nl
- Subject: Re: bash-2.x
- From: Chet Ramey <chet at nike dot ins dot cwru dot edu>
- Date: Thu, 23 Jul 1998 12:53:31 -0400
- Cc: yodl at icce dot rug dot nl, gnu-win32 at cygnus dot com
- Read-Receipt-To: chet@po.CWRU.Edu
- Reply-To: chet at po dot cwru dot edu
> jan@digicash.com writes:
> > Hi,
> >
> > After all this trouble with bash, i downloaded bash-docs-2.02,
> > and it says:
> >
> > for name [ in word; ] do list ; done
> ^
>
> >
> > 10:55:25 mub ~/ftp/gnu/bash-2.02$ for i in ;do echo $i; done
> > bash: syntax error near unexpected token `;d'
> >
> > It looks like a bug in bash-2.02(-release)
No. It is not a bug. If the `in' keyword is supplied, a non-empty
wordlist must be specified before the list terminator (the semicolon
or newline). You may leave out the `in' and the wordlist, in
which case it defaults to the positional parameters (as if `in "$@"'
had been supplied).
The text between the square brackets in the synopsis indicates an
optional unit, with one problem, described below. You can either
supply `in words' or nothing.
The description should more properly read
for name [ in word ] ; do list ; done
This is a documentation bug in the manual page that will be corrected
for the bash-2.03 release. The texinfo document has the correct syntax.
--
``The lyf so short, the craft so long to lerne.'' - Chaucer
Chet Ramey, Case Western Reserve University Internet: chet@po.CWRU.Edu
-
For help on using this list (especially unsubscribing), send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".