unset_rule_stack_limit: Unsets a restriction the maximum lcall depth of rules

Description Usage Arguments See Also Examples

View source: R/rule_stack.R

Description

Unsets the retriction that was set by set_rule_stack_limit

Usage

1

Arguments

parser,

a peg parser produced by new.parser

See Also

get_rule_stack, set_rule_stack_limit

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
## Not run: 
peg<-new.parser()
set_rule_stack_limit(peg, 10)
peg<-add_rule(peg, "A<-'a' A / ''" ) #consumes all a's at the beginning of a string
apply_rule(peg, "A", "aaaaaaaaaaaax") #there are 12 a's but will stop at 10
#error, rule stack depth limit exceeded
unset_rule_stack_limit(peg)
apply_rule(peg, "A", "aaaaaaaaaaaax") #now succeeds

## End(Not run)

mslegrand/pegr documentation built on May 23, 2019, 7:53 a.m.