Skip to content

Commit

Permalink
Fix - Deprecation Warning on DebugInspector
Browse files Browse the repository at this point in the history
  • Loading branch information
sinsuredpaul committed Mar 6, 2024
1 parent c910071 commit 60efee7
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion binding_of_caller.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -31,5 +31,5 @@ TXT

spec.require_paths = ["lib"]

spec.add_dependency "debug_inspector", ">= 0.0.1"
spec.add_dependency "debug_inspector", ">= 1.2.0"
end
4 changes: 2 additions & 2 deletions lib/binding_of_caller/mri.rb
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ def of_caller(n)
def callers
ary = []

RubyVM::DebugInspector.open do |dc|
DebugInspector.open do |dc|
locs = dc.backtrace_locations

locs.size.times do |i|
Expand All @@ -43,7 +43,7 @@ def frame_count
# @return [Symbol]
def frame_type
return nil if !@iseq

# apparently the 9th element of the iseq array holds the frame type
# ...not sure how reliable this is.
@frame_type ||= @iseq.to_a[9]
Expand Down

0 comments on commit 60efee7

Please sign in to comment.