Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: "[[" (Re: PATCH: _urls again (Re: setopt localoptions noautoremoveslash))
- X-seq: zsh-workers 8311
- From: Sven Wischnowsky <wischnow@xxxxxxxxxxxxxxxxxxxxxxx>
- To: zsh-workers@xxxxxxxxxxxxxx
- Subject: Re: "[[" (Re: PATCH: _urls again (Re: setopt localoptions noautoremoveslash))
- Date: Mon, 18 Oct 1999 08:59:42 +0200 (MET DST)
- In-reply-to: "Bart Schaefer"'s message of Sat, 16 Oct 1999 15:33:46 +0000
- Mailing-list: contact zsh-workers-help@xxxxxxxxxxxxxx; run by ezmlm
Bart Schaefer wrote:
> PWS says in http://www.ifh.de/~pws/computing/zshguide02.html#l6
>
> Second aside for users of sh: you may remember that tests in sh used
> a single pair of brackets, `if [ ... ]; then ...', or equivalently
> as a command called test, `if test ...; then ...'. The Korn shell
> was deliberately made to be different, and zsh follows that. The
> reason is that `[[' is treated specially, which allows the shell to
> do some extra checks and allows more natural syntax.
Here on zsh-workers we could probably say what the real difference is:
the parser knows about `[[ .. ]]' which should allow for faster
execution (I guess this is what Peter meant by `treated specially').
`[ .. ]' can only be handled as a normal builtin.
Bye
Sven
--
Sven Wischnowsky wischnow@xxxxxxxxxxxxxxxxxxxxxxx
Messages sorted by:
Reverse Date,
Date,
Thread,
Author