Chromium Code Reviews| Index: runtime/lib/array.dart |
| diff --git a/runtime/lib/array.dart b/runtime/lib/array.dart |
| index 01480f67f868c2d1094b7ff17a169ef6d7cdf53f..aa25cece54aff956720e82fcc08a6ac74a5c64fe 100644 |
| --- a/runtime/lib/array.dart |
| +++ b/runtime/lib/array.dart |
| @@ -73,9 +73,7 @@ class _ObjectArray<E> implements List<E> { |
| return Collections.reduce(this, initialValue, combine); |
| } |
| - Collection<E> where(bool f(E element)) { |
| - return Collections.where(this, new _GrowableObjectArray<E>(), f); |
| - } |
| + Iterable<E> where(bool f(E element)) => new WhereIterable<E>(this, f); |
|
Ivan Posva
2012/11/26 18:30:40
ditto: curlys
floitsch
2012/11/28 13:49:38
Done.
|
| bool every(bool f(E element)) { |
| return Collections.every(this, f); |
| @@ -218,9 +216,7 @@ class _ImmutableArray<E> implements List<E> { |
| return Collections.reduce(this, initialValue, combine); |
| } |
| - Collection<E> where(bool f(E element)) { |
| - return Collections.where(this, new _GrowableObjectArray<E>(), f); |
| - } |
| + Iterable<E> where(bool f(E element)) => new WhereIterable<E>(this, f); |
|
Ivan Posva
2012/11/26 18:30:40
ditto
floitsch
2012/11/28 13:49:38
Done.
|
| bool every(bool f(E element)) { |
| return Collections.every(this, f); |