Fix #7: add execute command
This commit adds support for a command execute
:
- param in [1, 2, 3];
- execute("solver " + str(param));
This commit takes the opportunity for some code refactoring:
-
write(...)
andexecute(...)
are no longer special rule forms, but are just functions that returns unit (aka void), and there is a single rule form- call(args);
for calling functions that return unit. -
There is now an enum type
SimpleRule
for rule forms that have no child rules: assignments, in, include, calls. -
There is now a struct
Context
to store the context of the interpreter.
Edited by Thierry Martinez