Public Member Functions | |
def | sort |
def | size |
def | __add__ |
def | __radd__ |
def | __mul__ |
def | __rmul__ |
def | __sub__ |
def | __rsub__ |
def | __or__ |
def | __ror__ |
def | __and__ |
def | __rand__ |
def | __xor__ |
def | __rxor__ |
def | __pos__ |
def | __neg__ |
def | __invert__ |
def | __div__ |
def | __truediv__ |
def | __rdiv__ |
def | __rtruediv__ |
def | __mod__ |
def | __rmod__ |
def | __le__ |
def | __lt__ |
def | __gt__ |
def | __ge__ |
def | __rshift__ |
def | __lshift__ |
def | __rrshift__ |
def | __rlshift__ |
![]() | |
def | as_ast |
def | get_id |
def | sort |
def | sort_kind |
def | __eq__ |
def | __hash__ |
def | __ne__ |
def | params |
def | decl |
def | num_args |
def | arg |
def | children |
![]() | |
def | __init__ |
def | __del__ |
def | __deepcopy__ |
def | __str__ |
def | __repr__ |
def | __eq__ |
def | __hash__ |
def | __nonzero__ |
def | __bool__ |
def | sexpr |
def | as_ast |
def | get_id |
def | ctx_ref |
def | eq |
def | translate |
def | __copy__ |
def | hash |
![]() | |
def | use_pp |
Additional Inherited Members | |
![]() | |
ast | |
ctx | |
def __add__ | ( | self, | |
other | |||
) |
Create the Z3 expression `self + other`. >>> x = BitVec('x', 32) >>> y = BitVec('y', 32) >>> x + y x + y >>> (x + y).sort() BitVec(32)
Definition at line 3240 of file z3py.py.
def __and__ | ( | self, | |
other | |||
) |
Create the Z3 expression bitwise-and `self & other`. >>> x = BitVec('x', 32) >>> y = BitVec('y', 32) >>> x & y x & y >>> (x & y).sort() BitVec(32)
Definition at line 3332 of file z3py.py.
def __div__ | ( | self, | |
other | |||
) |
Create the Z3 expression (signed) division `self / other`. Use the function UDiv() for unsigned division. >>> x = BitVec('x', 32) >>> y = BitVec('y', 32) >>> x / y x/y >>> (x / y).sort() BitVec(32) >>> (x / y).sexpr() '(bvsdiv x y)' >>> UDiv(x, y).sexpr() '(bvudiv x y)'
Definition at line 3409 of file z3py.py.
def __ge__ | ( | self, | |
other | |||
) |
Create the Z3 expression (signed) `other >= self`. Use the function UGE() for unsigned greater than or equal to. >>> x, y = BitVecs('x y', 32) >>> x >= y x >= y >>> (x >= y).sexpr() '(bvsge x y)' >>> UGE(x, y).sexpr() '(bvuge x y)'
Definition at line 3539 of file z3py.py.
def __gt__ | ( | self, | |
other | |||
) |
Create the Z3 expression (signed) `other > self`. Use the function UGT() for unsigned greater than. >>> x, y = BitVecs('x y', 32) >>> x > y x > y >>> (x > y).sexpr() '(bvsgt x y)' >>> UGT(x, y).sexpr() '(bvugt x y)'
Definition at line 3523 of file z3py.py.
def __invert__ | ( | self | ) |
Create the Z3 expression bitwise-not `~self`. >>> x = BitVec('x', 32) >>> ~x ~x >>> simplify(~(~x)) x
Definition at line 3398 of file z3py.py.
def __le__ | ( | self, | |
other | |||
) |
Create the Z3 expression (signed) `other <= self`. Use the function ULE() for unsigned less than or equal to. >>> x, y = BitVecs('x y', 32) >>> x <= y x <= y >>> (x <= y).sexpr() '(bvsle x y)' >>> ULE(x, y).sexpr() '(bvule x y)'
Definition at line 3491 of file z3py.py.
def __lshift__ | ( | self, | |
other | |||
) |
Create the Z3 expression left shift `self << other` >>> x, y = BitVecs('x y', 32) >>> x << y x << y >>> (x << y).sexpr() '(bvshl x y)' >>> simplify(BitVecVal(2, 3) << 1) 4
Definition at line 3585 of file z3py.py.
def __lt__ | ( | self, | |
other | |||
) |
Create the Z3 expression (signed) `other < self`. Use the function ULT() for unsigned less than. >>> x, y = BitVecs('x y', 32) >>> x < y x < y >>> (x < y).sexpr() '(bvslt x y)' >>> ULT(x, y).sexpr() '(bvult x y)'
Definition at line 3507 of file z3py.py.
def __mod__ | ( | self, | |
other | |||
) |
Create the Z3 expression (signed) mod `self % other`. Use the function URem() for unsigned remainder, and SRem() for signed remainder. >>> x = BitVec('x', 32) >>> y = BitVec('y', 32) >>> x % y x%y >>> (x % y).sort() BitVec(32) >>> (x % y).sexpr() '(bvsmod x y)' >>> URem(x, y).sexpr() '(bvurem x y)' >>> SRem(x, y).sexpr() '(bvsrem x y)'
Definition at line 3452 of file z3py.py.
def __mul__ | ( | self, | |
other | |||
) |
Create the Z3 expression `self * other`. >>> x = BitVec('x', 32) >>> y = BitVec('y', 32) >>> x * y x*y >>> (x * y).sort() BitVec(32)
Definition at line 3263 of file z3py.py.
def __neg__ | ( | self | ) |
Return an expression representing `-self`. >>> x = BitVec('x', 32) >>> -x -x >>> simplify(-(-x)) x
Definition at line 3387 of file z3py.py.
def __or__ | ( | self, | |
other | |||
) |
Create the Z3 expression bitwise-or `self | other`. >>> x = BitVec('x', 32) >>> y = BitVec('y', 32) >>> x | y x | y >>> (x | y).sort() BitVec(32)
Definition at line 3309 of file z3py.py.
def __pos__ | ( | self | ) |
def __radd__ | ( | self, | |
other | |||
) |
Create the Z3 expression `other + self`. >>> x = BitVec('x', 32) >>> 10 + x 10 + x
Definition at line 3253 of file z3py.py.
def __rand__ | ( | self, | |
other | |||
) |
Create the Z3 expression bitwise-or `other & self`. >>> x = BitVec('x', 32) >>> 10 & x 10 & x
Definition at line 3345 of file z3py.py.
def __rdiv__ | ( | self, | |
other | |||
) |
Create the Z3 expression (signed) division `other / self`. Use the function UDiv() for unsigned division. >>> x = BitVec('x', 32) >>> 10 / x 10/x >>> (10 / x).sexpr() '(bvsdiv #x0000000a x)' >>> UDiv(10, x).sexpr() '(bvudiv #x0000000a x)'
Definition at line 3432 of file z3py.py.
def __rlshift__ | ( | self, | |
other | |||
) |
Create the Z3 expression left shift `other << self`. Use the function LShR() for the right logical shift >>> x = BitVec('x', 32) >>> 10 << x 10 << x >>> (10 << x).sexpr() '(bvshl #x0000000a x)'
Definition at line 3613 of file z3py.py.
def __rmod__ | ( | self, | |
other | |||
) |
Create the Z3 expression (signed) mod `other % self`. Use the function URem() for unsigned remainder, and SRem() for signed remainder. >>> x = BitVec('x', 32) >>> 10 % x 10%x >>> (10 % x).sexpr() '(bvsmod #x0000000a x)' >>> URem(10, x).sexpr() '(bvurem #x0000000a x)' >>> SRem(10, x).sexpr() '(bvsrem #x0000000a x)'
Definition at line 3473 of file z3py.py.
def __rmul__ | ( | self, | |
other | |||
) |
Create the Z3 expression `other * self`. >>> x = BitVec('x', 32) >>> 10 * x 10*x
Definition at line 3276 of file z3py.py.
def __ror__ | ( | self, | |
other | |||
) |
Create the Z3 expression bitwise-or `other | self`. >>> x = BitVec('x', 32) >>> 10 | x 10 | x
Definition at line 3322 of file z3py.py.
def __rrshift__ | ( | self, | |
other | |||
) |
Create the Z3 expression (arithmetical) right shift `other` >> `self`. Use the function LShR() for the right logical shift >>> x = BitVec('x', 32) >>> 10 >> x 10 >> x >>> (10 >> x).sexpr() '(bvashr #x0000000a x)'
Definition at line 3599 of file z3py.py.
def __rshift__ | ( | self, | |
other | |||
) |
Create the Z3 expression (arithmetical) right shift `self >> other` Use the function LShR() for the right logical shift >>> x, y = BitVecs('x y', 32) >>> x >> y x >> y >>> (x >> y).sexpr() '(bvashr x y)' >>> LShR(x, y).sexpr() '(bvlshr x y)' >>> BitVecVal(4, 3) 4 >>> BitVecVal(4, 3).as_signed_long() -4 >>> simplify(BitVecVal(4, 3) >> 1).as_signed_long() -2 >>> simplify(BitVecVal(4, 3) >> 1) 6 >>> simplify(LShR(BitVecVal(4, 3), 1)) 2 >>> simplify(BitVecVal(2, 3) >> 1) 1 >>> simplify(LShR(BitVecVal(2, 3), 1)) 1
Definition at line 3555 of file z3py.py.
def __rsub__ | ( | self, | |
other | |||
) |
Create the Z3 expression `other - self`. >>> x = BitVec('x', 32) >>> 10 - x 10 - x
Definition at line 3299 of file z3py.py.
def __rtruediv__ | ( | self, | |
other | |||
) |
def __rxor__ | ( | self, | |
other | |||
) |
Create the Z3 expression bitwise-xor `other ^ self`. >>> x = BitVec('x', 32) >>> 10 ^ x 10 ^ x
Definition at line 3368 of file z3py.py.
def __sub__ | ( | self, | |
other | |||
) |
Create the Z3 expression `self - other`. >>> x = BitVec('x', 32) >>> y = BitVec('y', 32) >>> x - y x - y >>> (x - y).sort() BitVec(32)
Definition at line 3286 of file z3py.py.
def __truediv__ | ( | self, | |
other | |||
) |
def __xor__ | ( | self, | |
other | |||
) |
Create the Z3 expression bitwise-xor `self ^ other`. >>> x = BitVec('x', 32) >>> y = BitVec('y', 32) >>> x ^ y x ^ y >>> (x ^ y).sort() BitVec(32)
Definition at line 3355 of file z3py.py.
def size | ( | self | ) |
Return the number of bits of the bit-vector expression `self`. >>> x = BitVec('x', 32) >>> (x + 1).size() 32 >>> Concat(x, x).size() 64
Definition at line 3229 of file z3py.py.
Referenced by BitVecNumRef.as_signed_long().
def sort | ( | self | ) |
Return the sort of the bit-vector expression `self`. >>> x = BitVec('x', 32) >>> x.sort() BitVec(32) >>> x.sort() == BitVecSort(32) True
Definition at line 3218 of file z3py.py.
Referenced by BitVecRef.__add__(), BitVecRef.__and__(), BitVecRef.__div__(), BitVecRef.__mod__(), BitVecRef.__mul__(), BitVecRef.__or__(), BitVecRef.__sub__(), and BitVecRef.__xor__().