Last active
August 29, 2015 14:01
-
-
Save chadbailey59/b5f08b3359ef9a00e90f to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Tester | |
def foo | |
bar | |
end | |
def bar | |
baz | |
end | |
def baz | |
sleep 1 | |
end | |
end | |
t1 = Thread.new do | |
Tester.new.foo | |
end | |
puts "t1 started" | |
puts "t1 backtrace: #{t1.backtrace}" | |
t1.join | |
puts "t1 joined" | |
--- | |
t1 started | |
t1 backtrace: ["test.rb:11:in `sleep'", "test.rb:11:in `baz'", "test.rb:7:in `bar'", "test.rb:3:in `foo'", "test.rb:17:in `block in <main>'"] | |
t1 joined |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment