3
0
Fork 0
mirror of https://github.com/Z3Prover/z3 synced 2025-04-24 01:25:31 +00:00
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
Nikolaj Bjorner 2018-11-18 09:34:33 -08:00
parent fb1287155e
commit 6ef2557e2a
3 changed files with 50 additions and 61 deletions

View file

@ -6164,6 +6164,10 @@ class ModelRef(Z3PPObject):
def __deepcopy__(self):
return self.translate(self.ctx)
def Model(ctx = None):
ctx = _get_ctx(ctx)
return ModelRef(Z3_mk_model(ctx.ref()), ctx)
def is_as_array(n):
"""Return true if n is a Z3 expression of the form (_ as-array f)."""
return isinstance(n, ExprRef) and Z3_is_as_array(n.ctx.ref(), n.as_ast())