public string Interpret(Expr expression) { try { object value = Evaluate(expression); return(Stringify(value)); } catch (RuntimeException e) { Feebl.RuntimeError(e); return(null); } }
public void Interpret(List <Stmt> statements) { try { foreach (var stmt in statements) { Execute(stmt); } } catch (RuntimeException e) { Feebl.RuntimeError(e); } }
private ParseException Error(Token token, string msg) { Feebl.Error(token, msg); return(new ParseException()); }