You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
PhilippeSigaud edited this page Mar 18, 2012
·
15 revisions
Generating Code
Once a grammar is defined and a parse tree generated, how can it be used? We already saw how to use the parse tree in Using the Parse Tree, at runtime or compile-time. But since Pegged can parse at compile-time, the information can also be used to generate a string containing D code, which can in turn be mixed in standard D code.
This is exactly what Pegged itself does with the input you give it.