3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-04-15 05:18:44 +00:00

Revert "Change ASTVector to Expr[] in interpolation result"

This commit is contained in:
Nikolaj Bjorner 2015-05-22 08:24:45 -07:00
parent 034a9387ee
commit b4f72c8145

View file

@ -90,7 +90,7 @@ public class InterpolationContext extends Context
public class ComputeInterpolantResult
{
public Z3_lbool status = Z3_lbool.Z3_L_UNDEF;
public Expr[] interp = null;
public ASTVector interp = null;
public Model model = null;
};
@ -110,14 +110,7 @@ public class InterpolationContext extends Context
Native.LongPtr n_i = new Native.LongPtr();
Native.LongPtr n_m = new Native.LongPtr();
res.status =Z3_lbool.fromInt(Native.computeInterpolant(nCtx(), pat.getNativeObject(), p.getNativeObject(), n_i, n_m));
if (res.status == Z3_lbool.Z3_L_FALSE)
{
ASTVector seq = new ASTVector(this, n_i.value);
int n = seq.size();
res.interp = new Expr[n];
for (int i = 0; i < n; i++)
res.interp[i] = Expr.create(this, seq.get(i).getNativeObject());
}
if (res.status == Z3_lbool.Z3_L_FALSE) res.interp = new ASTVector(this, n_i.value);
if (res.status == Z3_lbool.Z3_L_TRUE) res.model = new Model(this, n_m.value);
return res;
}