[Patches] [ python-Patches-727789 ] Editing of __str__ and __repr__ docs

SourceForge.net noreply@sourceforge.net
Mon, 28 Apr 2003 21:52:50 -0700


Patches item #727789, was opened at 2003-04-25 17:25
Message generated for change (Comment added) made by rhettinger
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=727789&group_id=5470

Category: Documentation
Group: Python 2.3
Status: Open
Resolution: None
Priority: 5
Submitted By: Steven Taschuk (staschuk)
Assigned to: Nobody/Anonymous (nobody)
Summary: Editing of __str__ and __repr__ docs

Initial Comment:
A recent thread in comp.lang.python [1] suggests that
there is some question whether the existing docs for
the __str__ and __repr__ methods is clear, and whether
what it says is good in the first place.

The patch shows proposed changes based on the
discussions in that thread.  The new text treats __repr__
as a programmer-centric stringification (with eval(repr(x))
== x as a possibility, rather than a principle), and __str__
as a more general-purpose stringification-as-appropriate-
to-the-object.

[1] http://groups.google.com/groups?th=24b817d49ec3a59b

----------------------------------------------------------------------

>Comment By: Raymond Hettinger (rhettinger)
Date: 2003-04-28 23:52

Message:
Logged In: YES 
user_id=80475

The patch looks technically correct.  It is wordy and I liked 
the original better, but clarity is more important.

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=727789&group_id=5470