Skip to content

Commit

Permalink
In non-interactive mode, stop after first syntax error
Browse files Browse the repository at this point in the history
Don't keep going in this case; let the user fix the first error.

Signed-off-by: Keith Packard <keithp@keithp.com>
  • Loading branch information
keith-packard committed Jun 25, 2019
1 parent 5077a8d commit 9bd0d48
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions snek-parse.c
Expand Up @@ -195,6 +195,8 @@ snek_parse(void)
case parse_return_syntax:
default:
snek_error_syntax(snek_lex_text);
if (!snek_interactive)
return snek_parse_error;
{
/* Skip input until we get back to
* zero indent
Expand Down

0 comments on commit 9bd0d48

Please sign in to comment.