(%i17) 1 *** 2;
incorrect syntax: * is not a prefix operator
Apparently when it gets to "by", it throws out everything it's read so far, but leaves the rest of the line in the input buffer to be parsed. Then when it sees "do", it similarly throws out everything it's read so far. Then finally it reads 5 as though nothing preceded it.
It should of course have erred out leaving nothing in the input buffer.
Another similar case:
(%i24) for i by 4 do 5;
incorrect syntax: BY is an unknown keyword in a DO statement. <<< correct error msg
(%i24) incorrect syntax: DO is not an infix operator
Maxima 5.28 under XMaxima and wxMaxima under GCL on Windows
Log in to post a comment.