Method: Delorean::NodeAsValueNested#check

Defined in:
lib/delorean/nodes.rb

#check(context) ⇒ Object



205
206
207
208
209
210
211
212
213
214
215
216
217
# File 'lib/delorean/nodes.rb', line 205

def check(context, *)
  module_names = c.text_value.split('::')
  node_name = module_names.pop
  mname = module_names.join('::') if module_names.any?

  begin
    context.parse_check_defined_mod_node(node_name, mname)
  rescue UndefinedError, ParseError
    # Node is a non-Delorean ruby class
    context.parse_class(text_value)
  end
  []
end