diff --git a/prism/src/parser/ast/ConstantList.java b/prism/src/parser/ast/ConstantList.java index a84a842d..600646bb 100644 --- a/prism/src/parser/ast/ConstantList.java +++ b/prism/src/parser/ast/ConstantList.java @@ -353,9 +353,11 @@ public class ConstantList extends ASTElement allValues = new Values(); for (i = 0; i < numToEvaluate; i++) { Expression constant = cl.getConstant(i); + // NB: We use otherValues when evaluating here, but that shouldn't be needed + // since these values have already been plugged in by expandConstants above if (constant != null) { if (exact) { - BigRational r = constant.evaluateExact(null, otherValues); + BigRational r = constant.evaluateExact(otherValues); // handle differently, depending on constant type if (constant.getType() instanceof TypeDouble) { // we keep as BigRational for TypeDouble @@ -367,7 +369,7 @@ public class ConstantList extends ASTElement val = constant.getType().castFromBigRational(r); } } else { - val = constant.evaluate(null, otherValues); + val = constant.evaluate(otherValues); } allValues.addValue(cl.getConstantName(i), val); }