Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: comments break \ at end of line
- X-seq: zsh-workers 12696
- From: Peter Stephenson <pws@xxxxxxx>
- To: zsh-workers@xxxxxxxxxxxxxx (Zsh hackers list)
- Subject: Re: comments break \ at end of line
- Date: Fri, 25 Aug 2000 11:32:46 +0100
- In-reply-to: "Your message of Thu, 24 Aug 2000 22:29:32 BST." <20000824222932.A15971@xxxxxxxxxxxxxxxxxxxxxxx>
- Mailing-list: contact zsh-workers-help@xxxxxxxxxxxxxx; run by ezmlm
Adam wrote:
> % foo () {
> > echo hello, \
> > # this is a comment
> > world
> > }
> % foo
> hello,
> foo:3: command not found: world
>
> which is the same issue as
>
> % echo hello, \
> > # comment
> hello,
>
> This may be intentional, but if so, it strikes me as a rather
> undesirable feature, or at least one which you should be able to turn
> off.
I don't really see how it could be any different. The `\' just skips the
newline, turning the line into `echo hello, # this is a comment'. `\'
never forces it into any different state of parsing, it only escapes the
next character. What are you suggesting? I don't see how you can turn it
off without writing a completely new (= bugridden) way of lexing.
--
Peter Stephenson <pws@xxxxxxx> Software Engineer
Cambridge Silicon Radio, Unit 300, Science Park, Milton Road,
Cambridge, CB4 0XL, UK Tel: +44 (0)1223 392070
Messages sorted by:
Reverse Date,
Date,
Thread,
Author