We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 918d6c3 commit d86589bCopy full SHA for d86589b
spec/ruby/core/hash/shared/each.rb
@@ -28,11 +28,11 @@ def obj.foo(key, value)
28
end
29
30
ScratchPad.record([])
31
- { "a" => 1 }.each(&obj.method(:foo))
+ { "a" => 1 }.send(@method, &obj.method(:foo))
32
ScratchPad.recorded.should == ["a", 1]
33
34
35
- { "a" => 1 }.each(&-> key, value { ScratchPad << key << value })
+ { "a" => 1 }.send(@method, &-> key, value { ScratchPad << key << value })
36
37
38
0 commit comments