Class: C::TranslationUnit

Inherits:
Object
  • Object
show all
Defined in:
lib/cast-to-yaml/to_yaml.rb

Instance Method Summary collapse

Instance Method Details

#extract_declarations(res = Hash::new { |h, k| h[k] = [] }) ⇒ Object



88
89
90
91
92
93
94
95
# File 'lib/cast-to-yaml/to_yaml.rb', line 88

def extract_declarations(res = Hash::new { |h, k| h[k] = [] })
  entities.select { |e|
    e.kind_of? Declaration
  }.each { |e|
    e.extract(res)
  }
  res
end