the the result of eval as an object and call toString\(\) on it

This commit is contained in:
2020-02-03 23:42:49 +01:00
parent fc33ab6b12
commit 56463c3e30

View File

@@ -112,11 +112,7 @@ public class Klang {
System.out.println("\nEvaluating the source code:");
EvalVisitor evalVisitor = new EvalVisitor();
Value result = root.welcome(evalVisitor);
if (result != null) {
generateOutput(out, "Result was: TODO");
} else {
System.out.println("result was null");
}
generateOutput(out, "Result was: " + result.asObject().toString());
return;
}