1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* id.c (Init_id), vm.c (vm_exec): @#__ThrowState__ is no longer

used.  [ruby-dev:38760]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@24148 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2009-07-16 09:28:12 +00:00
parent fa41dad1b2
commit 415d5ebc2f
7 changed files with 38 additions and 24 deletions

View file

@ -223,4 +223,23 @@ class TestException < Test::Unit::TestCase
end
INPUT
end
def test_safe4
cmd = proc{raise SystemExit}
safe0_p = proc{|*args| args}
test_proc = proc {
$SAFE = 4
begin
cmd.call
rescue SystemExit => e
safe0_p["SystemExit: #{e.inspect}"]
raise e
rescue Exception => e
safe0_p["Exception (NOT SystemExit): #{e.inspect}"]
raise e
end
}
assert_raise(SystemExit, '[ruby-dev:38760]') {test_proc.call}
end
end