Skip to content

Latest commit

 

History

History
61 lines (41 loc) · 2.42 KB

grammar.rst

File metadata and controls

61 lines (41 loc) · 2.42 KB

Changing CPython's Grammar

Abstract

There's more to changing Python's grammar than editing :file:`Grammar/python.gram`. Here's a checklist.

NOTE: These instructions are for Python 3.9 and beyond. Earlier versions use a different parser technology. You probably shouldn't try to change the grammar of earlier Python versions, but if you really want to, use GitHub to track down the earlier version of this file in the devguide. (Python 3.9 itself actually supports both parsers; the old parser can be invoked by passing -X oldparser.)

Checklist

Note: sometimes things mysteriously don't work. Before giving up, try make clean.