test_hash.rb: suppress warnings
* test/ruby/test_hash.rb (test_rehash2, test_callcc_iter_level): suppress shadowing outer local variable warnings. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44357 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
3a18a62d44
commit
16863d903b
@ -788,7 +788,7 @@ class TestHash < Test::Unit::TestCase
|
||||
assert_equal("foobarbaz", h.default_proc.call("foo", "bar"))
|
||||
assert_nil(h.default_proc = nil)
|
||||
assert_nil(h.default_proc)
|
||||
h.default_proc = ->(h, k){ true }
|
||||
h.default_proc = ->(_,_){ true }
|
||||
assert_equal(true, h[:nope])
|
||||
h = @cls[]
|
||||
assert_nil(h.default_proc)
|
||||
@ -1013,7 +1013,7 @@ class TestHash < Test::Unit::TestCase
|
||||
assert_nothing_raised(RuntimeError, bug9105) do
|
||||
h=@cls[]
|
||||
cnt=0
|
||||
c = callcc {|c|c}
|
||||
c = callcc {|cc|cc}
|
||||
h[cnt] = true
|
||||
h.each{|i|
|
||||
cnt+=1
|
||||
|
Loading…
x
Reference in New Issue
Block a user