Module: Treetop::Compiler::Metagrammar::Choice2

Defined in:
lib/treetop/compiler/metagrammar.rb

Instance Method Summary collapse

Instance Method Details

#alternativesObject



712
713
714
# File 'lib/treetop/compiler/metagrammar.rb', line 712

def alternatives
  [head] + tail
end

#inline_modulesObject



720
721
722
# File 'lib/treetop/compiler/metagrammar.rb', line 720

def inline_modules
  (alternatives.map {|alt| alt.inline_modules }).flatten
end

#tailObject



716
717
718
# File 'lib/treetop/compiler/metagrammar.rb', line 716

def tail
  super.elements.map {|elt| elt.alternative}
end