Skip to content

Commit

Permalink
Enable default values for unbounded domains
Browse files Browse the repository at this point in the history
  • Loading branch information
mondokm committed Feb 20, 2024
1 parent b09d67f commit a3b3071
Showing 1 changed file with 10 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -68,16 +68,16 @@ public RecursiveIntObjMapView<? extends MddNode> toCanonicalRepresentation(MddVa
}

// Check if default
// if (!ExprUtils.getConstants(canonizedExpr).contains(decl)) {
// final MddNode childNode;
// if (mddVariable.getLower().isPresent()) {
// childNode = mddVariable.getLower().get().checkInNode(new MddExpressionTemplate(canonizedExpr, o -> (Decl) o, solverPool));
// } else {
// final MddGraph<Expr> mddGraph = (MddGraph<Expr>) mddVariable.getMddGraph();
// childNode = mddGraph.getNodeFor(canonizedExpr);
// }
// return MddExpressionRepresentation.ofDefault(canonizedExpr, decl, mddVariable, solverPool, childNode);
// }
if (mddVariable.getDomainSize() == 0 && !ExprUtils.getConstants(canonizedExpr).contains(decl)) {
final MddNode childNode;
if (mddVariable.getLower().isPresent()) {
childNode = mddVariable.getLower().get().checkInNode(new MddExpressionTemplate(canonizedExpr, o -> (Decl) o, solverPool));
} else {
final MddGraph<Expr> mddGraph = (MddGraph<Expr>) mddVariable.getMddGraph();
childNode = mddGraph.getNodeFor(canonizedExpr);
}
return MddExpressionRepresentation.ofDefault(canonizedExpr, decl, mddVariable, solverPool, childNode);
}

return MddExpressionRepresentation.of(canonizedExpr, decl, mddVariable, solverPool);

Expand Down

0 comments on commit a3b3071

Please sign in to comment.