mirror of
https://github.com/python/cpython.git
synced 2025-07-07 19:35:27 +00:00
Updates to track Grammar changes. The patch to token.py loosens the regexp to
allow "testlist1" to be snagged.
This commit is contained in:
parent
d389036069
commit
adf1606161
2 changed files with 3 additions and 1 deletions
|
@ -76,6 +76,8 @@ argument = 318
|
|||
list_iter = 319
|
||||
list_for = 320
|
||||
list_if = 321
|
||||
testlist1 = 322
|
||||
encoding_decl = 323
|
||||
#--end constants--
|
||||
|
||||
sym_name = {}
|
||||
|
|
|
@ -98,7 +98,7 @@ def main():
|
|||
lines = fp.read().split("\n")
|
||||
fp.close()
|
||||
prog = re.compile(
|
||||
"#define[ \t][ \t]*([A-Z][A-Z_]*)[ \t][ \t]*([0-9][0-9]*)",
|
||||
"#define[ \t][ \t]*([A-Z0-9][A-Z0-9_]*)[ \t][ \t]*([0-9][0-9]*)",
|
||||
re.IGNORECASE)
|
||||
tokens = {}
|
||||
for line in lines:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue