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 r.david.murray
Recipients Dave, mark.dickinson, r.david.murray, vstinner
Date 2013-02-06.19:56:26
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1360180586.63.0.406140306203.issue17139@psf.upfronthosting.co.za>
In-reply-to
Content
You are correct.  Effectively every class has an __str__, and that is what gets called when you print something without specifying any other formatting.  (I say effectively, because if there is no __str__ the __repr__ gets used, which every class *does* have via inheritance from the base object 'object'.)

For what it is worth, I just gave David Beasly's "Python Essential Reference" to someone who is a relatively new Python programmer but an experienced programmer, and he loved it.
History
Date User Action Args
2013-02-06 19:56:26r.david.murraysetrecipients: + r.david.murray, mark.dickinson, vstinner, Dave
2013-02-06 19:56:26r.david.murraysetmessageid: <1360180586.63.0.406140306203.issue17139@psf.upfronthosting.co.za>
2013-02-06 19:56:26r.david.murraylinkissue17139 messages
2013-02-06 19:56:26r.david.murraycreate