[issue5133] Error with Eval

Ezio Melotti report at bugs.python.org
Mon Feb 2 20:04:13 CET 2009


Ezio Melotti <ezio.melotti at gmail.com> added the comment:

The leading zero is used to define octal numbers, 8 and 9 are not valid
octal digits, see
http://docs.python.org/reference/lexical_analysis.html#integer-and-long-integer-literals

Also, you don't need to use eval to reproduce that behavior.

The number displayed is the decimal equivalent:
>>> 07
7
>>> 010
8

----------
nosy: +ezio.melotti

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue5133>
_______________________________________


More information about the Python-bugs-list mailing list