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 Steven.Barker
Recipients Steven.Barker
Date 2014-05-10.00:35:04
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1399682105.99.0.768132721109.issue21389@psf.upfronthosting.co.za>
In-reply-to
Content
Ah, I figured out why using %R may be bad. It breaks for the following silly class:

    class C():
        def __repr__(self):
            return repr(self.__repr__) # or use any other bound method

repr(C()) will recurse until the recursion limit is hit, both with and without my patch. If this seems like a real issue, I could probably replace the %R code with a variation on the base case code in PyObject_Repr:

    PyUnicode_FromFormat("<%s object at %p>",
                         v->ob_type->tp_name, v)
History
Date User Action Args
2014-05-10 00:35:06Steven.Barkersetrecipients: + Steven.Barker
2014-05-10 00:35:05Steven.Barkersetmessageid: <1399682105.99.0.768132721109.issue21389@psf.upfronthosting.co.za>
2014-05-10 00:35:05Steven.Barkerlinkissue21389 messages
2014-05-10 00:35:04Steven.Barkercreate