class Byebug::Context

Constants

IGNORED_XML_FILES

Public Class Methods

ignored(path)
Also aliased as: ignored_without_xml
Alias for: ignored_with_xml
ignored_with_xml(path) click to toggle source
# File lib/byebug/context_xml.rb, line 16
def ignored_with_xml(path)
  result = ignored_without_xml(path) ||
    IGNORED_XML_FILES.include?(path) ||
    !!path.match(/^\(eval\)/) ||
    !!path.match(/rdebug-vim$/) ||
    !!path.match(/rdebug-ide$/)
  result
end
Also aliased as: ignored
ignored_without_xml(path)
Alias for: ignored
stack_size(byebug_frames = false) click to toggle source
# File lib/byebug/context_xml.rb, line 6
def stack_size(byebug_frames = false)
  backtrace = Thread.current.backtrace_locations(0)
  return 0 unless backtrace

  unless byebug_frames
    backtrace = backtrace.select { |l| !ignored(l.path) }
  end
  backtrace.size
end