useful commands:
import ParseTree;
import Syntax;
t = parse(#start[Form], |project://sle-rug/examples/tax.myql|, allowAmbiguity=true);
import IDE;
main();
First 2 steps from Create Parse Tree for File
. Then:
import CST2AST;
ast = cst2ast(t);
import IDE;
import ParseTree;
import AST;
import CST2AST;
import Syntax;
t = parse(#start[Form], |project://sle-rug/examples/tax.myql|, allowAmbiguity=true);
ast = cst2ast(t);
check(ast);
import IDE;
import ParseTree;
import AST;
import CST2AST;
import Syntax;
import Compile;
import Eval;
tax = parse(#start[Form], |project://sle-rug/examples/tax.myql|, allowAmbiguity=true);
ast = cst2ast(tax);
env = initialEnv(ast);
// Example eval
eval(ast, input("hasBoughtHouse", vbool(true)), env)