On 3/30/06, Aahz <[EMAIL PROTECTED]> wrote: > What do we want to tell people who have code like this: > > keys = d.keys() > keys.sort() > > Not so much in terms of the fix, but where/why we drew the line about > what's supported by the value returned by d.keys() and what's not. I'm > not getting clarity about that from this discussion so far, and I think > it's needed.
That's a really good point; we need a meta-PEP on how to handle this kind of issues. In this particular case I'm convinced that we must allow such code to break (perhaps silently or painfully); making keys() return an iterator has been on the Python 3000 agenda for years (pretty much since iterators were first introduced in Python 2.2). -- --Guido van Rossum (home page: http://www.python.org/~guido/) _______________________________________________ Python-3000 mailing list Python-3000@python.org http://mail.python.org/mailman/listinfo/python-3000 Unsubscribe: http://mail.python.org/mailman/options/python-3000/archive%40mail-archive.com