diff options
| author | Yukihiro "Matz" Matsumoto <[email protected]> | 2018-09-19 22:19:55 +0900 |
|---|---|---|
| committer | Yukihiro "Matz" Matsumoto <[email protected]> | 2018-09-19 22:19:55 +0900 |
| commit | 747059a718b9c6538891a21df69bad9998c51ad0 (patch) | |
| tree | cee6be6a11aa63a9f0b9ab037f0cba96b860c7fd /mrbgems/mruby-enumerator | |
| parent | b6c5e501b370e0758e9f1e224b2dd363df4f0998 (diff) | |
| download | mruby-747059a718b9c6538891a21df69bad9998c51ad0.tar.gz mruby-747059a718b9c6538891a21df69bad9998c51ad0.zip | |
Removed `to_ary` conversion method.
Diffstat (limited to 'mrbgems/mruby-enumerator')
| -rw-r--r-- | mrbgems/mruby-enumerator/mrblib/enumerator.rb | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/mrbgems/mruby-enumerator/mrblib/enumerator.rb b/mrbgems/mruby-enumerator/mrblib/enumerator.rb index 22856a91b..ae692dd12 100644 --- a/mrbgems/mruby-enumerator/mrblib/enumerator.rb +++ b/mrbgems/mruby-enumerator/mrblib/enumerator.rb @@ -621,9 +621,7 @@ module Enumerable # use Enumerator to use infinite sequence def zip(*args, &block) args = args.map do |a| - if a.respond_to?(:to_ary) - a.to_ary.to_enum(:each) - elsif a.respond_to?(:each) + if a.respond_to?(:each) a.to_enum(:each) else raise TypeError, "wrong argument type #{a.class} (must respond to :each)" |
