Skip to content

Instantly share code, notes, and snippets.

@jjb
Created August 14, 2014 15:07
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jjb/3174471215cb6b908ddd to your computer and use it in GitHub Desktop.
Save jjb/3174471215cb6b908ddd to your computer and use it in GitHub Desktop.
def a
raise "i am in a"
end
def b
puts "i am in b"
a
end
def c
puts "i am in c"
b
end
c
➔ ruby exceptiontest.rb
i am in c
i am in b
exceptiontest.rb:2:in `a': i am in a (RuntimeError)
from exceptiontest.rb:7:in `b'
from exceptiontest.rb:12:in `c'
from exceptiontest.rb:15:in `<main>'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment