Re: [Python-Dev] Add a frozendict builtin type

2012年2月28日 04:02:06 -0800

On 2012年2月28日 12:45:54 +0100
Victor Stinner <[email protected]> wrote:
> > I think you need to elaborate on your use cases further, ...
> 
> A frozendict can be used as a member of a set or as a key in a dictionary.
> 
> For example, frozendict is indirectly needed when you want to use an
> object as a key of a dict, whereas one attribute of this object is a
> dict.
It isn't. You just have to define __hash__ correctly.
> frozendict helps also in threading and multiprocessing.
How so?
Regards
Antoine.
_______________________________________________
Python-Dev mailing list
[email protected]
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Reply via email to