Re: [Python-Dev] r59947 - in python/trunk:Lib/test/test_structseq.py Misc/NEWS

2008-01-13 Thread Raymond Hettinger
>> 1. Have structseq subclass from PyTupleObject so that isinstance(s, tuple) >> returns True. This makes the object usable whenever >> tuples are needed. > > Hmm, is that really necessary? structseq has been in use for quite a > while and this need hasn't come up -- it's been designed to be qui

Re: [Python-Dev] r59947 - in python/trunk:Lib/test/test_structseq.py Misc/NEWS

2008-01-13 Thread Christian Heimes
Raymond Hettinger wrote: > FWIW, I was looking into something similar but didn't proceed because it > would break eval(repr(s)) == s as the constructor signature > wants all the args in a tuple and won't accept keywords. Still, I think what > you did is a nice improvement. I agree that eval(re

Re: [Python-Dev] r59947 - in python/trunk:Lib/test/test_structseq.py Misc/NEWS

2008-01-13 Thread Guido van Rossum
On Jan 13, 2008 7:53 PM, Raymond Hettinger <[EMAIL PROTECTED]> wrote: > [Christian Heimes] > > Log: > > Added new an better structseq representation. E.g. repr(time.gmtime(0)) now > > returns 'time.struct_time(tm_year=1970, tm_mon=1, > > tm_mday=1, tm_hour=0, tm_min=0, tm_sec=0, tm_wday=3, tm_yday