The result object only has a spot for one exception, but you can have more than one if you fork. Eg there should be errors reported on both branches of the if statement here:
begin
if fork # => 18920, nil
raise 'some irrelevant error'
else
Queue.new.shift # ~> fatal: No live threads left. Deadlock?
end
ensure
$!.class.name == 'fatal' # => false, true
$!.message =~ /deadlock/i # => nil, 22
end
The result object only has a spot for one exception, but you can have more than one if you fork. Eg there should be errors reported on both branches of the if statement here: