"tostring" as a string method?

Warren Postma embed at geocities.com
Fri Apr 7 09:07:16 EDT 2000


>
> Meanwhile, on the biopthon.org list, Jeff Chang pointed out that
> __str__ is in general an ill-defined quantity.  The usual
> interpretation is that __str__ returns a human-representation while
> __repr__ returns a computer representation.  So using __str__
> to return the character stream is not the right interface.  We're
> now using "tostring()", which is more obvious.
>

Hmm. Have you considered marshalling everything instead?

Warren





More information about the Python-list mailing list