Class Sexp
In: lib/roodi/core/visitable_sexp.rb
Parent: Object

Methods

Public Instance methods

[Source]

# File lib/roodi/core/visitable_sexp.rb, line 5
  def accept(visitor)
    visitor.visit(self)
  end

[Source]

# File lib/roodi/core/visitable_sexp.rb, line 13
  def children
    find_all { | sexp | Sexp === sexp }
  end

[Source]

# File lib/roodi/core/visitable_sexp.rb, line 17
  def is_language_node?
    first.class == Symbol
  end

[Source]

# File lib/roodi/core/visitable_sexp.rb, line 9
  def node_type
    first
  end

[Source]

# File lib/roodi/core/visitable_sexp.rb, line 21
  def visitable_children
    parent = is_language_node? ? sexp_body : self
    parent.children
  end

[Validate]