mirror of
git://git.code.sf.net/p/zsh/code
synced 2025-10-31 18:10:56 +01:00
11606: Propagate parse errors out of parse_list() and parse_event(), and
test that it worked.
This commit is contained in:
parent
17aadf0338
commit
47532f255e
3 changed files with 11 additions and 7 deletions
|
|
@ -459,6 +459,7 @@ par_event(void)
|
|||
}
|
||||
}
|
||||
if (!r) {
|
||||
tok = LEXERR;
|
||||
if (errflag) {
|
||||
yyerror(0);
|
||||
ecused--;
|
||||
|
|
@ -491,10 +492,8 @@ parse_list(void)
|
|||
yylex();
|
||||
init_parse();
|
||||
par_list(&c);
|
||||
#if 0
|
||||
if (tok == LEXERR)
|
||||
#endif
|
||||
if (tok != ENDINPUT) {
|
||||
if (tok != ENDINPUT) {
|
||||
tok = LEXERR;
|
||||
yyerror(0);
|
||||
return NULL;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue