Left recursion elimination
Rewrite recursive grammar rules into a form that is easier to use in predictive parsers.
Learn. Transform. Build.
Compiler Forge Toolkit is a free, browser-based learning companion for students and educators studying context-free grammars, parsing, and compiler construction.
Input grammar
E → E + T | T
Transform
Understand
Go deeper
Use the Compiler Forge Handbook and companion code examples to connect each transformation with the theory behind it.
A clearer way to learn
Turn difficult grammar transformations into approachable, repeatable exercises with instant, structured feedback.
Rewrite recursive grammar rules into a form that is easier to use in predictive parsers.
Refactor common prefixes in productions to make grammar decisions clearer for LL parsing.
Compute essential parsing sets with readable output that helps you verify each result.