REPL accepts invalid input that starts with a valid complete expression #12

Closed
opened 2026-06-16 11:23:32 +02:00 by st · 0 comments
Owner
> 12 fld 3
12 : i64
> :ast 12 fld 3
(Integer 12)

The first input is accepted and appears to evaluate to something nonsensical, because 12 followed by something that is not in the follow set of 12 in expression is a valid complete expression.

REPL should probably reject input that parses correctly without parsing the complete input, or at least provide a warning.

``` > 12 fld 3 12 : i64 > :ast 12 fld 3 (Integer 12) ``` The first input is accepted and appears to evaluate to something nonsensical, because `12` followed by something that is not in the follow set of `12` in expression is a valid complete expression. REPL should probably reject input that parses correctly without parsing the complete input, or at least provide a warning.
st closed this issue 2026-06-21 21:30:22 +02:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
st/amelie#12
No description provided.