Skip to content
Snippets Groups Projects
Commit c74ec30d authored by Michael Leuschel's avatar Michael Leuschel
Browse files

exception when expression in recursive op case empty

parent 890e9374
No related branches found
No related tags found
No related merge requests found
Pipeline #98680 passed
...@@ -377,8 +377,13 @@ public class Theories { ...@@ -377,8 +377,13 @@ public class Theories {
prologOutput.openTerm("case"); prologOutput.openTerm("case");
prologOutput.printAtom(indArg); prologOutput.printAtom(indArg);
prologOutput.openList(); prologOutput.openList();
if(ex==null) {
throw new IllegalStateException("Empty expression for axiomatic recursive definition case " + es +
" and inductive argument " + indArg);
} else {
for (FreeIdentifier fi : ex.getFreeIdentifiers()) { for (FreeIdentifier fi : ex.getFreeIdentifiers()) {
prologOutput.printAtom(fi.getName()); prologOutput.printAtom(fi.getName());
}
} }
prologOutput.closeList(); prologOutput.closeList();
printExpression(prologOutput, ex); printExpression(prologOutput, ex);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment