wyz23x2 <[email protected]> added the comment:
Another 2 problems:
1.
>>> 0b1112
File "<stdin>", line 1
0b1112
^
SyntaxError: invalid digit '2' in binary literal
>>> 0o5780
File "<stdin>", line 1
0o5780
^
SyntaxError: invalid digit '8' in octal literal
But:
>>> 0x2fag
File "<stdin>", line 1
0x2fag
^^^^^^
SyntaxError: invalid syntax. Perhaps you forgot a comma?
>>>
Is this expected?
2.
>>> 0o91
File "<stdin>", line 1
0o91
^
SyntaxError: invalid digit '9' in octal literal
>>> 0b21
File "<stdin>", line 1
0b21
^
SyntaxError: invalid digit '2' in binary literal
The ^ is misplaced again, even though, say the 0b1112 example above works.
----------
title: Misleading mark of octal SyntaxErrors -> Problems of int literal
SyntaxErrors
_______________________________________
Python tracker <[email protected]>
<https://bugs.python.org/issue44317>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe:
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com