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 jaebae17
Recipients jaebae17
Date 2014-11-26.19:47:16
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1417031236.3.0.00389201998154.issue22951@psf.upfronthosting.co.za>
In-reply-to
Content
The help page for the built-in repr() states ''' For many types, this function makes an attempt to return a string that would yield an object with the same value when passed to eval()...'''

This holds true for non-inf/nan values of float():
>>> eval(repr(float('0.0')))
0.0

But for inf, -inf, and nan it does not:
>>> eval(repr(float('inf')))
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "<string>", line 1, in <module>
NameError: name 'inf' is not defined

Expected return from repr(float('inf')) was "float('inf')", but perhaps 'inf' response has too much history at this point to be changed.
History
Date User Action Args
2014-11-26 19:47:16jaebae17setrecipients: + jaebae17
2014-11-26 19:47:16jaebae17setmessageid: <1417031236.3.0.00389201998154.issue22951@psf.upfronthosting.co.za>
2014-11-26 19:47:16jaebae17linkissue22951 messages
2014-11-26 19:47:16jaebae17create