diff options
author | Kazuhiro NISHIYAMA <zn@mbf.nifty.com> | 2019-06-21 17:08:42 +0900 |
---|---|---|
committer | Kazuhiro NISHIYAMA <zn@mbf.nifty.com> | 2019-06-21 17:11:11 +0900 |
commit | 887163beb8f27c5400cd04dbf98c474ed035526f (patch) | |
tree | 40cf9bcf2891faa593efe49759278f6ee4d34526 /enumerator.c | |
parent | 0174285e8cfea1ab7fa8dbbb6ab7607d74c20b9d (diff) | |
download | ruby-887163beb8f27c5400cd04dbf98c474ed035526f.tar.gz |
Fix call-seq of lazy.filter_map [ci skip]
Diffstat (limited to 'enumerator.c')
-rw-r--r-- | enumerator.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/enumerator.c b/enumerator.c index 3d19c40b15..21a7389708 100644 --- a/enumerator.c +++ b/enumerator.c @@ -2038,12 +2038,11 @@ lazy_filter_map_proc(RB_BLOCK_CALL_FUNC_ARGLIST(val, m)) /* * call-seq: - * enum.filter_map { |obj| block } -> an_enumerator - * enum.filter_map -> an_enumerator + * lazy.filter_map { |obj| block } -> lazy_enumerator * * Returns an enumerator which will return a new array containing the * truthy results (everything except +false+ or +nil+) of running the - * +block+ for every element in +enum+. + * +block+ for every element in +lazy+. * * (1..).lazy.filter_map { |i| i * 2 if i.even? }.take(5) #=> [4, 8, 12, 16, 20] * |