Mutable objects which define __hash__ (was Re: Why are tuples immutable?)

Nick Coghlan ncoghlan at
Thu Dec 23 13:01:06 CET 2004

Antoon Pardon wrote:
> I don't think I would recommend adding hash methods to mutable builtins.
> Storing keys by identity or value both can make sense for these kind
> of objects. And since python prefers not to guess I think it is a good thing
> there is no default hash for mutable objects.

In that case, I don't think we now disagree on anything more substantial than 
what the __hash__ documentation in the Language Reference should be saying :)


Nick Coghlan   |   ncoghlan at   |   Brisbane, Australia

More information about the Python-list mailing list