[Python-Dev] PEP 218 (sets); moving set.py to Lib
Tue, 20 Aug 2002 19:56:53 -0400
On Tue, Aug 20, 2002, Raymond Hettinger wrote:
> 1. Rename .remove() to __del__(). Its usage is inconsistent with
> list.remove(element) which can leave other instances of element in the
> list. It is more consistent with 'del adict[element]'.
You mean __delitem__, I think. __del__ is only for deleting the object
itself when its refcount goes to zero.
> 3. Should we add .as_temporarily_immutable to dictionaries and lists
> so that they will also be potential elements of a set?
There's been some talk in the past about creating lockable dicts and
lists (emphasis on dicts because lists have tuple-equivalence).
Aahz (firstname.lastname@example.org) <*> http://www.pythoncraft.com/
Project Vote Smart: http://www.vote-smart.org/