[Python-Dev] why doesn't print pass unicode strings on to the file
object?
Martin von Loewis
loewis@informatik.hu-berlin.de
Tue, 18 Sep 2001 18:23:17 +0200 (MEST)
> > What user code exactly would break? Would that be a serious problem?
>
> All code which assumes a tuple as return value. It's hard to
> say how much code makes such an assumption. Most Python
> code probably only uses the sequence interface, but the C interface
> was deliberately designed to return tuples so that C programmers
> can easily access the data.
I believe that code would continue to work if you got a instance of a
tuple subtype.
> I don't see a need to argue over this. It's no use putting
> a lot of work into inventing some overly complex (subclassing
> types, etc.) strategy to maintain backwards compatibility
> when an easy solution is so close at hand.
Subclassing tuples is not at all overly complex.
Regards,
Martin