This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author doerwalter
Recipients
Date 2001-09-11.11:31:44
SpamBayes Score
Marked as misclassified
Message-id
In-reply-to
Content
Logged In: YES 
user_id=89016

Thanks for the quick fix, but the second problem still 
remains:
---
class U(unicode):
   pass

u = U(u"foo")

print type(u[0:3])
print type(u[0:2])
---
This gives:
---
<type '__main__.U'>
<type 'unicode'>
---
I think this should be changed to either always return a 
unicode object, or to always return an instance of the real 
class passed in. (This should be done for all unicode 
methods that return a new unicode object). The second 
solution would simplify creating derived classes, because 
all the methods that return unicode objects would 
automatically return the derived type, so these methods 
don't have to be overwritten.
History
Date User Action Args
2007-08-23 13:56:19adminlinkissue460020 messages
2007-08-23 13:56:19admincreate