Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(264)

Unified Diff: sdk/lib/collection/list.dart

Issue 2467113003: Make EfficientLength extend Iterable. (Closed)
Patch Set: Reverted, prepare to reland. Make new test not break web-testing framework. Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « sdk/lib/collection/iterable.dart ('k') | sdk/lib/collection/maps.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sdk/lib/collection/list.dart
diff --git a/sdk/lib/collection/list.dart b/sdk/lib/collection/list.dart
index 7e6dbd3adc18306ba52249a85ea852921eec7a17..8b6713aeb839bf99fc87ddeba90a52b0a8388c51 100644
--- a/sdk/lib/collection/list.dart
+++ b/sdk/lib/collection/list.dart
@@ -395,7 +395,7 @@ abstract class ListMixin<E> implements List<E> {
void replaceRange(int start, int end, Iterable<E> newContents) {
RangeError.checkValidRange(start, end, this.length);
- if (newContents is! EfficientLength) {
+ if (newContents is! EfficientLengthIterable) {
newContents = newContents.toList();
}
int removeLength = end - start;
@@ -482,7 +482,7 @@ abstract class ListMixin<E> implements List<E> {
void insertAll(int index, Iterable<E> iterable) {
RangeError.checkValueInInterval(index, 0, length, "index");
- if (iterable is! EfficientLength || identical(iterable, this)) {
+ if (iterable is! EfficientLengthIterable || identical(iterable, this)) {
iterable = iterable.toList();
}
int insertionLength = iterable.length;
« no previous file with comments | « sdk/lib/collection/iterable.dart ('k') | sdk/lib/collection/maps.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698