A prime field. Use SolverFor('QF_FF') for incremental field solving.
Definition at line 12643 of file z3py.py.
Try to cast `val` as an element of sort `self`.
This method is used in Z3Py to convert Python objects such as integers,
floats, longs and strings into Z3 expressions.
>>> x = Int('x')
>>> RealSort().cast(x)
ToReal(x)
Reimplemented from SortRef.
Definition at line 12648 of file z3py.py.
12648 def cast(self, value):
12649 if is_expr(value):
12650 if not self.eq(value.sort()):
12651 raise Z3Exception("finite-field sort mismatch")
12652 return value
12653 return FiniteFieldVal(value, self)
12654
12655