@@ -0,0 +1,1161 @@
+package com.madisp.bad;%0A%0Aimport com.madisp.bad.eval.BadConverter;%0Aimport com.madisp.bad.eval.BadScope;%0Aimport com.madisp.bad.expr.Expression;%0Aimport com.madisp.bad.expr.ExpressionFactory;%0A%0Aimport java.io.BufferedReader;%0Aimport java.io.IOException;%0Aimport java.io.InputStreamReader;%0A%0A/**%0A * Created with IntelliJ IDEA.%0A * User: madis%0A * Date: 5/18/13%0A * Time: 6:25 PM%0A */%0Apublic class ConsoleRepl %7B%0A%09public static void main(String%5B%5D args) throws IOException %7B%0A%09%09ExpressionFactory factory = new ExpressionFactory();%0A%09%09BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));%0A%09%09System.out.println(%22Repl running, type 'exit' to quit.%22);%0A%09%09BadScope scope = new BadScope(null, new Object());%0A%09%09String s;%0A%09%09while (!(s = getLine(reader)).equals(%22exit%22)) %7B%0A%09%09%09if (s.isEmpty()) %7B%0A%09%09%09%09continue;%0A%09%09%09%7D%0A%09%09%09try %7B%0A%09%09%09%09Expression expr = factory.buildExpression(s);%0A%09%09%09%09System.out.println(BadConverter.string(expr.value(scope)));%0A%09%09%09%7D catch (Exception e) %7B%0A%09%09%09%09e.printStackTrace();%0A%09%09%09%7D%0A%09%09%7D%0A%09%7D%0A%0A%09private static String getLine(BufferedReader reader) throws IOException %7B%0A%09%09System.out.print(%22%3E %22);%0A%09%09System.out.flush();%0A%09%09return reader.readLine().trim();%0A%09%7D%0A%7D%0A

Add plain old Java main class with a script REPL