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

Unified Diff: pkg/unittest/lib/src/collection_matchers.dart

Issue 12328104: Change new List(n) to return fixed length list. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Merge to head. Created 7 years, 10 months 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
Index: pkg/unittest/lib/src/collection_matchers.dart
diff --git a/pkg/unittest/lib/src/collection_matchers.dart b/pkg/unittest/lib/src/collection_matchers.dart
index 80ac42811de4ba2f78dd41ffa47abf819b0fb2af..30e38f6bf95e1867900668de1086be4647d74eb0 100644
--- a/pkg/unittest/lib/src/collection_matchers.dart
+++ b/pkg/unittest/lib/src/collection_matchers.dart
@@ -142,7 +142,7 @@ class _UnorderedEquals extends BaseMatcher {
} else if (expectedLength < actualLength) {
return 'has too many elements (${actualLength} > ${expectedLength})';
}
- List<bool> matched = new List<bool>.fixedLength(actualLength);
+ List<bool> matched = new List<bool>(actualLength);
for (var i = 0; i < actualLength; i++) {
matched[i] = false;
}

Powered by Google App Engine
This is Rietveld 408576698