Files
codeql/python/extractor/tests/parser/exception_groups_new.py
Taus 9c913902c5 Python: Allow except* to be written as except *
Turns out, `except*` is actually not a token on its own according to the
Python grammar. This means it's legal to write `except *foo: ...`, which
we previously would consider a syntax error.

To fix it, we simply break up the `except*` into two separate tokens.
2024-10-22 15:39:29 +00:00

27 lines
210 B
Python

try:
a
b
except* c:
d
e
except* f as g:
h
i
except* (j, k):
l
m
except* (n, o) as p:
q
r
else:
s
t
finally:
u
v
try:
pass
except *foo as e:
pass