Method: EBNF::PEG::Parser::ClassMethods#start_production
- Defined in:
- lib/ebnf/peg/parser.rb
#start_production(term, **options) {|data, block| ... } ⇒ Object
Defines a production called at the beggining of a particular production with data from previous production along with data defined for the current production. Block is called in an evaluation block from the enclosing parser.
Yield to generate a triple
114 115 116 117 |
# File 'lib/ebnf/peg/parser.rb', line 114 def start_production(term, **, &block) start_handlers[term] = block [term] = .freeze end |