gazayas / masamune-ast

A covenience wrapper around Prism, a Ruby source code parser
MIT License
13 stars 1 forks source link

Get nodes by type #45

Open gazayas opened 1 year ago

gazayas commented 1 year ago

I'd like to return a list of nodes according to the type passed:

msmn.get_nodes_by_type(:var_field)

This would then return a list of all Masamune::AbstractSyntaxTree::VarField objects in msmn.node_list.