Difference of hash and __hash__()
Mel Wilson
mwilson at the-wire.com
Fri Sep 5 10:35:02 EDT 2003
In article <mailman.1062731175.11423.python-list at python.org>,
Michael Chermside <mcherm at mcherm.com> wrote:
>So submit the bugreport, but I'm guessing that slices will remain
>unhashable. IIRC, Guido felt that the risk of confusion (folks
>thinking that {}[1:2] would return some part or subset of the dict)
>was greater than the utility of using slices as keys in a dict
>(for which, I believe, he was unable to come up with a single
>plausible use case).
Anybody with one might have to settle for
a_dict [repr (a_slice)] ...
Regards. Mel.
More information about the Python-list
mailing list