You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When running the calculator, the first number in a full line cannot be a negative number. In either the interpreter, JIT, or VM, it errors with the following message: called `Result::unwrap()\` on an `Err` value: Error { variant: ParsingError { positives: [EOI], negatives: [] }, location: Pos(3), line_col: Pos((1, 4)), path: None, line: "-1 + 2", continued_line: None }.
To Reproduce
Run the calculator compiler by cargo run --bin repl --features vm | jit | interpreter.
Give the input -NUMBER + NUMBER such as -2 + 5.
Output gives an error.
Expected behavior
Instead of giving an error the interpreter should return the calculated result. For example, -2 + 5 should output 3.
The text was updated successfully, but these errors were encountered:
Description
When running the calculator, the first number in a full line cannot be a negative number. In either the interpreter, JIT, or VM, it errors with the following message:
called `Result::unwrap()\` on an `Err` value: Error { variant: ParsingError { positives: [EOI], negatives: [] }, location: Pos(3), line_col: Pos((1, 4)), path: None, line: "-1 + 2", continued_line: None }
.To Reproduce
cargo run --bin repl --features vm | jit | interpreter
.-NUMBER + NUMBER
such as-2 + 5
.Expected behavior
Instead of giving an error the interpreter should return the calculated result. For example,
-2 + 5
should output3
.The text was updated successfully, but these errors were encountered: