Module: Ctags::Ruby

Extended by:
Ruby
Included in:
Ruby
Defined in:
lib/ctags/ruby.rb

Instance Method Summary collapse

Instance Method Details

#tags_for_file(file, data = nil) ⇒ Object



7
8
9
10
11
12
13
14
15
16
17
# File 'lib/ctags/ruby.rb', line 7

def tags_for_file(file, data=nil)
  data ||= File.read(file)
  RipperTags::Parser.extract(data, file)
rescue Errno::ENOENT
  raise Error, $!.message
rescue Interrupt
  raise
rescue Object => e
  STDERR.puts [e, file].inspect
  []
end