On Tue, Aug 29, 2006, Guido van Rossum wrote: > On 8/29/06, Greg Ewing <[EMAIL PROTECTED]> wrote: >> Guido van Rossum wrote: >>> >>> Having views in a library module alleviates many of my objections. >>> While I still worry that it will be overused, deque doesn't seem to >>> be overused, so perhaps I should relax. >> >> Another thought is that there will already be ways in which Py3k >> views could lead to inefficiencies if they're not used carefully. A >> keys() view of a dict, for example, will keep the values of the dict >> alive as well as the keys, unlike the existing keys() method. > > Right; but I don't expect that such a keys() view will typically have > a lifetime longer than the dict.
That's true only for newer code that correctly uses sets instead of dicts -- but we've had this argument before. -- Aahz ([EMAIL PROTECTED]) <*> http://www.pythoncraft.com/ "Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it." --Brian W. Kernighan _______________________________________________ Python-3000 mailing list [email protected] http://mail.python.org/mailman/listinfo/python-3000 Unsubscribe: http://mail.python.org/mailman/options/python-3000/archive%40mail-archive.com
