constant: equality

This commit is contained in:
Sebastien Bourdeauducq 2012-01-07 12:29:47 +01:00
parent 7b395b565e
commit b6763c28ea
1 changed files with 3 additions and 0 deletions

View File

@ -121,6 +121,9 @@ class Constant(Value):
def __repr__(self):
return str(self.bv) + str(self.n)
def __eq__(self, other):
return self.bv == other.bv and self.n == other.n
def _cst(x):
if isinstance(x, int):