rename bosl to phisol

This commit is contained in:
Torsten Ruger
2015-10-07 15:22:47 +03:00
parent f88fc8bba1
commit 99098951ca
26 changed files with 38 additions and 38 deletions

23
lib/phisol/ast_helper.rb Normal file
View File

@@ -0,0 +1,23 @@
AST::Node.class_eval do
def [](name)
#puts self.inspect
children.each do |child|
if child.is_a?(AST::Node)
#puts child.type
if (child.type == name)
return child.children
end
else
#puts child.class
end
end
nil
end
def first_from( node_name )
from = self[node_name]
return nil unless from
from.first
end
end