Description Usage Details See Also Examples
The pegR rule debugger allows one to step through as the rules as they are invoked.
1 | debug.pegR(peg)
|
When applying a given rule to to a text input string, that rule may call other rules which in turn may call other rules, ad nausem. The peg rule debugger allows one to step through that calling sequence, examining the state of the parsing both upon entering a rule and and exiting a rule.
1 2 3 4 5 6 7 8 | ## Not run:
pegR<-new.parser()
debug.pegR(pegR)
pegR + "A<-B" + "B<-C" + "C<-'abc'"
pegR[['A']]('abc')
undebug.pegR(pegR)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.