Fix error output

This commit is contained in:
Dianne Skoll
2025-10-30 18:00:34 -04:00
parent 4158ad5977
commit 7a319466cf
2 changed files with 3 additions and 2 deletions

View File

@@ -2759,6 +2759,7 @@ expr_node *parse_expression(char const **e, int *r, Var *locals)
print_expr_tree(node, ErrFp);
fprintf(ErrFp, "\n");
}
orig = o2;
}
if (**e && (**e != ']')) {
if (DebugFlag & DB_PARSE_EXPR) {

View File

@@ -23906,7 +23906,7 @@ Parsed expression: 1||1
Parsed expression: 2
=> 2
Unparsed: , 3
, 3
2, 3
^-- here
../tests/expr.rem(15): Expecting end-of-expression
Parsed expression: iif(0, "foo", 0, "bar", 1, "blech", 0, "quux", 1, "borhy", "wacka")
@@ -23926,7 +23926,7 @@ max(6, 9, 50) => 50
Parsed expression: max(1,
=> Error: Illegal character
Unparsed: ,1)
,1)
max(1,,1)
^-- here
Parsed expression: 5%0
=> (% 5 0)