commit | ac7a92cc0a821699df48bc2e30a02c25d6338f78 | [log] [tgz] |
---|---|---|
author | Pablo Galindo <Pablogsal@gmail.com> | Sun May 10 05:34:50 2020 +0100 |
committer | GitHub <noreply@github.com> | Sat May 09 21:34:50 2020 -0700 |
tree | d7f301b66d79b6d3ce497669a99a5f9ce47ba3b5 | |
parent | 2c3d508c5fabe40dac848fb9ae558069f0576879 [diff] |
bpo-40334: Avoid collisions between parser variables and grammar variables (GH-19987) This is for the C generator: - Disallow rule and variable names starting with `_` - Rename most local variable names generated by the parser to start with `_` Exceptions: - Renaming `p` to `_p` will be a separate PR - There are still some names that might clash, e.g. - anything starting with `Py` - C reserved words (`if` etc.) - Macros like `EXTRA` and `CHECK`