Commit a32b90c2 authored by Robert Bradshaw's avatar Robert Bradshaw

complex number coercion fix

parent ab0acc7a
...@@ -883,6 +883,12 @@ class CComplexType(CNumericType): ...@@ -883,6 +883,12 @@ class CComplexType(CNumericType):
else: else:
return False return False
def __ne__(self, other):
if isinstance(self, CComplexType) and isinstance(other, CComplexType):
return self.real_type != other.real_type
else:
return True
def __lt__(self, other): def __lt__(self, other):
if isinstance(self, CComplexType) and isinstance(other, CComplexType): if isinstance(self, CComplexType) and isinstance(other, CComplexType):
return self.real_type < other.real_type return self.real_type < other.real_type
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment