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 terry.reedy
Recipients cvrebert, ethan.furman, jaebae17, mark.dickinson, serhiy.storchaka, terry.reedy
Date 2014-11-29.01:17:59
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1417223881.21.0.172519131155.issue22951@psf.upfronthosting.co.za>
In-reply-to
Content
Enhancements are only possible in 3.5 or beyond.  I agree with Mark. There is no compelling reason to break code with this change.  Hence it should be rejected.

Float is an odd duck.  All ints and all non-recursive lists, for instance, have a literal representation, and repr used that.  No range objects, for instance, have a literal representation, so repr uses a evaluable 'range(start, stop[, step])'  All float objects except 3 have a literal representation.

Int and float are both unusual builtins in parsing a string input to produce a non-string object.  For int, eval(repr(i)) == int(repr(i)) == i for all ints i.  Similarly, eval(repr(f)) == float(repr(f)) == f for all float objects f *except* for the same 3 special objects.  For those 3, a choice was make and we should stick with it.
History
Date User Action Args
2014-11-29 01:18:01terry.reedysetrecipients: + terry.reedy, mark.dickinson, cvrebert, ethan.furman, serhiy.storchaka, jaebae17
2014-11-29 01:18:01terry.reedysetmessageid: <1417223881.21.0.172519131155.issue22951@psf.upfronthosting.co.za>
2014-11-29 01:18:00terry.reedylinkissue22951 messages
2014-11-29 01:18:00terry.reedycreate