Skip to content

Commit

Permalink
redefines_eq_and_hash: optimization
Browse files Browse the repository at this point in the history
  • Loading branch information
markotoplak committed Aug 31, 2022
1 parent 3986008 commit bdaee7d
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions Orange/data/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -339,8 +339,4 @@ def redefines_eq_and_hash(this):
if this.__hash__ is None:
return False

for o in this.mro()[1:]:
if this.__eq__ is o.__eq__ or this.__hash__ is o.__hash__:
return False

return True
return "__hash__" in this.__dict__ and "__eq__" in this.__dict__

0 comments on commit bdaee7d

Please sign in to comment.