[Python-Dev] printing xrange objects (original) (raw)
Thomas Wouters thomas@xs4all.net
Thu, 3 Aug 2000 17:00:03 +0200
- Previous message: [Python-Dev] printing xrange objects
- Next message: [Python-Dev] printing xrange objects
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On Thu, Aug 03, 2000 at 09:06:51AM -0400, Fred L. Drake, Jr. wrote:
There is no tpstr handler, so str(xrange(...)) is the same as repr(xrange(...)). I propose ripping out the tpprint handler completely. (And I've already tested my patch. ;) Comments?
+0... I would say 'swap str and repr', because str(xrange) does what repr(xrange) should do, and the other way 'round:
x = xrange(1000) repr(x) (0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, ... ... ... ... 998, 999)
str(x) '(xrange(0, 1000, 1) * 1)'
But I don't really care either way.
-- Thomas Wouters <thomas@xs4all.net>
Hi! I'm a .signature virus! copy me into your .signature file to help me spread!
- Previous message: [Python-Dev] printing xrange objects
- Next message: [Python-Dev] printing xrange objects
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]