Closed
Description
I believe this was partially introduced by #8465. I ran into this issue while looking into microsoft/pyright#5446.
According to the python docs, a type that redefines __eq__
but not __hash__
is unhashable.
In the current typeshed hints, many types explicitly define __eq__
(int for example) but do not define hash. A type checker could incorrectly assume that the type is unhashable because of this.
Metadata
Metadata
Assignees
Labels
No labels