kopia lustrzana https://github.com/NanoVNA-Saver/nanovna-saver
Merge pull request #475 from silbe/version-recursion-fix
Version: avoid infinite recursionpull/482/head
commit
4d4ff52c15
|
@ -54,13 +54,13 @@ class Version:
|
|||
return False
|
||||
|
||||
def __lt__(self, other: "Version") -> bool:
|
||||
return other > self
|
||||
return other.__gt__(self)
|
||||
|
||||
def __ge__(self, other: "Version") -> bool:
|
||||
return self > other or self == other
|
||||
return self.__gt__(other) or self.__eq__(other)
|
||||
|
||||
def __le__(self, other: "Version") -> bool:
|
||||
return self < other or self == other
|
||||
return other.__gt__(self) or self.__eq__(other)
|
||||
|
||||
def __eq__(self, other: "Version") -> bool:
|
||||
return self.data == other.data
|
||||
|
|
Ładowanie…
Reference in New Issue