* new lexing bug, and possible fix
@ 1996-07-16 19:44 Zefram
0 siblings, 0 replies; only message in thread
From: Zefram @ 1996-07-16 19:44 UTC (permalink / raw)
To: Z Shell workers mailing list
-----BEGIN PGP SIGNED MESSAGE-----
zsh -fc 'echo ${'
Index: Src/lex.c
===================================================================
RCS file: /home/zefram/usr/cvsroot/zsh/Src/lex.c,v
retrieving revision 1.7
diff -c -r1.7 lex.c
*** lex.c 1996/07/16 14:26:55 1.7
--- lex.c 1996/07/16 18:20:32
***************
*** 715,721 ****
}
c = Outpar;
} else {
! if (e == '{') {
add(c);
c = Inbrace;
++bct;
--- 715,721 ----
}
c = Outpar;
} else {
! if (e == '{') { /*}*/
add(c);
c = Inbrace;
++bct;
***************
*** 768,774 ****
break;
case LX2_INBRACE:
if (isset(IGNOREBRACES) || sub)
! c = '{';
else {
if (in_brace_param)
cmdpush(CS_BRACE);
--- 768,774 ----
break;
case LX2_INBRACE:
if (isset(IGNOREBRACES) || sub)
! c = '{'; /*}*/
else {
if (in_brace_param)
cmdpush(CS_BRACE);
***************
*** 964,969 ****
--- 964,972 ----
brk:
hungetc(c);
*bptr = '\0';
+ if (in_brace_param)
+ while(bct-- >= in_brace_param)
+ cmdpop();
DPUTS(cmdsp != ocmdsp, "BUG: gettok: cmdstack changed.");
return peek;
}
-----BEGIN PGP SIGNATURE-----
Version: 2.6.2
iQCVAwUBMeveTnD/+HJTpU/hAQG0bQP/QWxzgTrcGS9jnaqeK5FC73epXRJQNXE1
5z84WhUpSxfuZ8Eoiyo6eo6jL4ZUZ2opaMUvjZabPZj/TIC3EOjT1xUksLdN8Na8
FZsFTZUNEP94cDh51MbZMQ4s7/nspZiAB8F/aY9lh0dF6x25uUcNTIMMsbBleIKV
owzhlSYeevs=
=cw0M
-----END PGP SIGNATURE-----
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~1996-07-16 19:50 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1996-07-16 19:44 new lexing bug, and possible fix Zefram
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).