Brad Miller <[EMAIL PROTECTED]> added the comment: On Tue, Jun 17, 2008 at 12:23 AM, Martin v. Löwis <[EMAIL PROTECTED]> wrote: > > Martin v. Löwis <[EMAIL PROTECTED]> added the comment: > > After reviewing this again, I'm skeptical that this is a good idea. It > doesn't achieve its original purpose (anymore), as it only changes > tp_str for range objects (although it does change tp_repr for dict views > - why this inconsistency?). > The reason for the inconsistency is that there was a strong argument that the tp_repr for range already returned something useful that people could take advantage of in their code. The same was not the case for the dict views.
I do not understand why you think that having the interpreter display <dict_keys: 2, 3, 4, ...> when x.keys() is called is not an improvement over <dict_keys object at 0xe72b0> Maybe it is just because I spend a lot more time in the interactive interpreter that I see this as a big improvement. So if, as Raymond Hettinger suggests, the interpreter is the right place to make this change I'd still be happy to provide a patch if someone could give me a pointer for where to start looking. Brad > So I'm -0 on the patch, meaning that I won't commit it, but won't object > to anybody else committing it, either. > > Technically, in dictview_repr, the first call to PyUnicode_Concat isn't > checked for exceptions. > > _______________________________________ > Python tracker <[EMAIL PROTECTED]> > <http://bugs.python.org/issue2610> > _______________________________________ > _______________________________________ Python tracker <[EMAIL PROTECTED]> <http://bugs.python.org/issue2610> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com