Skip to content

Commit 35ea5e0

Browse files
committed
Prevent warnings of &proc idiom
1 parent 17d28f1 commit 35ea5e0

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

lib/pycall/dict.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,9 @@ def delete(key)
3333
v
3434
end
3535

36-
def each
36+
def each(&block)
3737
return enum_for unless block_given?
38-
LibPython::Helpers.dict_each(__pyptr__, &proc)
38+
LibPython::Helpers.dict_each(__pyptr__, &block)
3939
self
4040
end
4141

lib/pycall/list.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,9 @@ def length
1313
PyCall.len(self)
1414
end
1515

16-
def each
16+
def each(&block)
1717
return enum_for unless block_given?
18-
LibPython::Helpers.sequence_each(__pyptr__, &proc)
18+
LibPython::Helpers.sequence_each(__pyptr__, &block)
1919
self
2020
end
2121

0 commit comments

Comments
 (0)