New submission from Batuhan Taskaya <isidenti...@gmail.com>:
$ python -X oldparser Python 3.10.0a0 (heads/bpo-xxxxx:f2947e354c, May 21 2020, 18:54:57) [GCC 9.2.1 20191008] on linux Type "help", "copyright", "credits" or "license" for more information. >>> (()): int File "<stdin>", line 1 SyntaxError: only single target (not tuple) can be annotated >>> ((())): int File "<stdin>", line 1 SyntaxError: only single target (not tuple) can be annotated >>> (((()))): int File "<stdin>", line 1 SyntaxError: only single target (not tuple) can be annotated >>> ([]): int File "<stdin>", line 1 SyntaxError: only single target (not list) can be annotated >>> (([])): int File "<stdin>", line 1 SyntaxError: only single target (not list) can be annotated ---- current ---- >>> (()): int File "<stdin>", line 1 (()): int ^ SyntaxError: illegal target for annotation >>> (((()))): int File "<stdin>", line 1 (((()))): int ^ SyntaxError: illegal target for annotation >>> ([]): int File "<stdin>", line 1 ([]): int ^ SyntaxError: illegal target for annotation >>> (([])): int File "<stdin>", line 1 (([])): int ^ SyntaxError: illegal target for annotation ---------- messages: 369885 nosy: BTaskaya priority: normal severity: normal status: open title: Pegen: cover extra surrounding parentheses for invalid annotated assignment _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue40769> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com