Class: Riml::Compiler::DrillDownVisitor

Inherits:
Visitor
  • Object
show all
Defined in:
lib/compiler.rb

Overview

helper to drill down to all descendants of a certain node and do something to all or a set of them

Direct Known Subclasses

EstablishScopeVisitor

Instance Method Summary collapse

Methods inherited from Visitor

#initialize, #visit

Constructor Details

This class inherits a constructor from Riml::Compiler::Visitor

Instance Method Details

#walk_node!(node) ⇒ Object



506
507
508
509
510
# File 'lib/compiler.rb', line 506

def walk_node!(node)
  node.each do |expr|
    expr.accept(self) if expr.respond_to?(:accept)
  end if node.respond_to?(:each)
end