Skip to content

Commit 14c46c2

Browse files
authored
elf/section: Remove __hash__ (#659)
self.header: Container is not hashable as it is modifiable. Remove __hash__() from Section. Closes: #539 Signed-off-by: Philipp Hahn <phahn-oss@avm.de>
1 parent c6cb7d7 commit 14c46c2

1 file changed

Lines changed: 0 additions & 3 deletions

File tree

elftools/elf/sections.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -134,9 +134,6 @@ def __getitem__(self, name: str) -> Any:
134134
def __eq__(self, other: object) -> bool:
135135
return isinstance(other, Section) and self.header == other.header
136136

137-
def __hash__(self) -> int:
138-
return hash(self.header)
139-
140137

141138
class NullSection(Section):
142139
""" ELF NULL section

0 commit comments

Comments
 (0)