Behavior of print statements and IO statements
Currently, in case of any error no (further) print statements are evaluated though they might be error-free. It would be nice that errors are emitted per print statement gracefully and the control flow is not aborted but continued with the next print and I/O statements.
Example model:
a = 1
b = 2 [m]
c = a + b
d = a * b
print(c)
print(d)
The result is this error message:
Dimensionality error: /pfs/data5/home/kit/scc/jk7683/vre-language/examples/14.vm:3:5 --> a + b <--
Cannot convert from 'dimensionless' (dimensionless) to 'meter' ([length])
One has to comment the print(c)
line causing the error in order to see the result from the print(d)
line. For interactive sessions and in Jupyter this feature is maybe not important.
Edited by Ivan Kondov