Commit 9467c481 authored by Mark Florisson's avatar Mark Florisson

CythonUtilityCode Py3 compat

parent 4078e677
...@@ -242,10 +242,11 @@ class StringSourceDescriptor(SourceDescriptor): ...@@ -242,10 +242,11 @@ class StringSourceDescriptor(SourceDescriptor):
def get_filenametable_entry(self): def get_filenametable_entry(self):
return "stringsource" return "stringsource"
# Do not hash on the name, an identical string source should be the def __hash__(self):
# same object (name is often defaulted in other places) return id(self)
# def __hash__(self): # Do not hash on the name, an identical string source should be the
# return hash(self.name) # same object (name is often defaulted in other places)
# return hash(self.name)
def __eq__(self, other): def __eq__(self, other):
return isinstance(other, StringSourceDescriptor) and self.name == other.name return isinstance(other, StringSourceDescriptor) and self.name == other.name
......
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