Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: PATCH: Re: Bug in ${(z)...} lexing, or what?
- X-seq: zsh-workers 12243
- From: Sven Wischnowsky <wischnow@xxxxxxxxxxxxxxxxxxxxxxx>
- To: zsh-workers@xxxxxxxxxxxxxx
- Subject: Re: PATCH: Re: Bug in ${(z)...} lexing, or what?
- Date: Thu, 13 Jul 2000 14:23:20 +0200 (MET DST)
- In-reply-to: Sven Wischnowsky's message of Thu, 13 Jul 2000 10:40:19 +0200 (MET DST)
- Mailing-list: contact zsh-workers-help@xxxxxxxxxxxxxx; run by ezmlm
I wrote:
> ...
>
> Now we need a way to detect which opening parens in conditions are
> parts of words and I'm not sure where and when to do that (Peter?).
The parser uses the `trick' to increment/decrement incond at the
appropriate places. This seems to do the right thing to make
bufferwords() do the same (well, it only sets incond to 2 at the right
places).
Anyone sees a problem with this?
Bye
Sven
Index: Src/hist.c
===================================================================
RCS file: /cvsroot/zsh/zsh/Src/hist.c,v
retrieving revision 1.10
diff -u -r1.10 hist.c
--- Src/hist.c 2000/07/13 08:42:10 1.10
+++ Src/hist.c 2000/07/13 12:22:30
@@ -2099,6 +2099,10 @@
strinbeg(0);
noaliases = 1;
do {
+ if (incond)
+ incond = 1 + (tok != DINBRACK && tok != INPAR &&
+ tok != DBAR && tok != DAMPER &&
+ tok != BANG);
ctxtlex();
if (tok == ENDINPUT || tok == LEXERR)
break;
--
Sven Wischnowsky wischnow@xxxxxxxxxxxxxxxxxxxxxxx
Messages sorted by:
Reverse Date,
Date,
Thread,
Author