Sha256: 72f6bc090f362853ab0570534c927e209d7ef5f155cd1ff593668bc79ffd7f5c
Contents?: true
Size: 337 Bytes
Versions: 8
Compression:
Stored size: 337 Bytes
Contents
require 'sexp' class Sexp def accept(visitor) visitor.visit(self) end def node_type first end def children find_all { | sexp | Sexp === sexp } end def is_language_node? first.class == Symbol end def visitable_children parent = is_language_node? ? sexp_body : self parent.children end end
Version data entries
8 entries across 8 versions & 1 rubygems