Fix comparison using != (Issue #11).

git-svn-id: http://llvm-py.googlecode.com/svn/trunk@45 8d1e9007-1d4e-0410-b67e-1979fd6579aa
This commit is contained in:
mdevan.foobar 2008-11-05 02:47:31 +00:00
commit ecdc9ebd95
3 changed files with 13 additions and 0 deletions

View file

@ -1,6 +1,7 @@
0.4, in progress:
* Fix comparison using != (Issue #11).
* Instruction.is_terminator added.
* Fix Builder.select (Paulo Silva).
* Added viewCFG methods to Function (Paulo Silva).

View file

@ -798,6 +798,9 @@ class Module(llvm.Ownable):
else:
return False
def __ne__(self, rhs):
return not self == rhs
def _get_target(self):
return _core.LLVMGetTarget(self.ptr)
@ -1074,6 +1077,9 @@ class Type(object):
else:
return False
def __ne__(self, rhs):
return not self == rhs
def refine(self, dest):
"""Refine the abstract type represented by self into a concrete class.
@ -1273,6 +1279,9 @@ class Value(object):
else:
return False
def __ne__(self, rhs):
return not self == rhs
def _get_name(self):
return _core.LLVMGetValueName(self.ptr)

View file

@ -129,6 +129,9 @@ def do_type():
vt = Type.vector(ti, 100)
s = vt.element
s = vt.count
Type.int(32) == Type.int(64)
Type.int(32) != Type.int(64)
Type.int(32) != Type.float()
def do_typehandle():