Open JoeStrout opened 10 months ago
Note that this might be fixed incidentally if we implement suggestion #100.
I came across this issue when testing how accurately Miniscript can tell me which line an error occurred on.
I expected an error for "unknown function fution" or similar on line 1 of the code below, but instead it crashes the interpreter (presumably because the end function
is now "extra")
bread = fution(x) b = "butter" + x end function
So it does! (In the C++ implementation; not in the C# one.) Good catch.
In command-line MiniScript, if you type
end function
at the prompt without first starting a function, it aborts (exit code 134). It should instead just print an error and continue.Note that
end if
andend while
work correctly; onlyend function
shows this problem.