Actions
Bug #13320
closedrescue blocks get an entry in backtrace locations
Bug #13320:
rescue blocks get an entry in backtrace locations
Actions
Added by bughit (bug hit) over 9 years ago. Updated about 7 years ago.
def foo
puts caller(0) # (1)
end
def bar
p 0
begin # (3)
p 1
raise
p 2
rescue
foo # (2)
end
end
bar # (4)
#=>
0
1
(1) t.rb:2:in `foo'
(2) t.rb:12:in `rescue in bar'
(3) t.rb:7:in `bar'
(4) t.rb:16:in `<main>'
(3) shows they are in begin/end clause and
(2) shows they are in rescue clause.
does it make sense?