On 6/09/20 8:08 am, David Mertz wrote:
Lots of people have noted that being able to eval a repr is only a vague goal in Python, that works *often* at most.
Still, the fact that it *almost* works for floats, except for certain specific values, is a bit annoying. Maybe the solution is for the repr of a float to be float('inf') instead of just 'inf'. That still wouldn't work with literal_eval, but I've realised that literal_eval only works on tuples, not lists, so it's of limited use anyway. -- Greg _______________________________________________ Python-ideas mailing list -- python-ideas@python.org To unsubscribe send an email to python-ideas-le...@python.org https://mail.python.org/mailman3/lists/python-ideas.python.org/ Message archived at https://mail.python.org/archives/list/python-ideas@python.org/message/EGPRIEZLA36EPRYT7ZNK5RHVAYDYAU4G/ Code of Conduct: http://python.org/psf/codeofconduct/