Loading e-Knife/src/main/java/eknife/erlang/ErlangLASTFactory.java +4 −0 Original line number Diff line number Diff line Loading @@ -46,6 +46,8 @@ public class ErlangLASTFactory extends LASTFactory final Launcher launcher = Launcher.getLauncher(); final OtpErlangObject response = launcher.launch("ast", "getASTs", sourcePath); final OtpErlangTuple tuple = (OtpErlangTuple) response; if (!(tuple.elementAt(1) instanceof OtpErlangList)) throw new RuntimeException("The erlang program could not be loaded: " + tuple.elementAt(1).toString()); final OtpErlangList asts = (OtpErlangList) tuple.elementAt(1); final ErlangLASTFactory lastFactory = new ErlangLASTFactory(sourcePath); Loading Loading @@ -186,6 +188,8 @@ public class ErlangLASTFactory extends LASTFactory break; case "eof": break; case "error": throw new RuntimeException("Parsing of the Erlang code has failed. Re-check the input program."); default: throw new RuntimeException("Type not contemplated: " + type.atomValue()); } Loading Loading
e-Knife/src/main/java/eknife/erlang/ErlangLASTFactory.java +4 −0 Original line number Diff line number Diff line Loading @@ -46,6 +46,8 @@ public class ErlangLASTFactory extends LASTFactory final Launcher launcher = Launcher.getLauncher(); final OtpErlangObject response = launcher.launch("ast", "getASTs", sourcePath); final OtpErlangTuple tuple = (OtpErlangTuple) response; if (!(tuple.elementAt(1) instanceof OtpErlangList)) throw new RuntimeException("The erlang program could not be loaded: " + tuple.elementAt(1).toString()); final OtpErlangList asts = (OtpErlangList) tuple.elementAt(1); final ErlangLASTFactory lastFactory = new ErlangLASTFactory(sourcePath); Loading Loading @@ -186,6 +188,8 @@ public class ErlangLASTFactory extends LASTFactory break; case "eof": break; case "error": throw new RuntimeException("Parsing of the Erlang code has failed. Re-check the input program."); default: throw new RuntimeException("Type not contemplated: " + type.atomValue()); } Loading