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

Unified Diff: tools/dom/templates/immutable_list_mixin.darttemplate

Issue 14175013: Add setAll, insertAll, replaceRange and fillRange. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 8 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: tools/dom/templates/immutable_list_mixin.darttemplate
diff --git a/tools/dom/templates/immutable_list_mixin.darttemplate b/tools/dom/templates/immutable_list_mixin.darttemplate
index ae81f68e0bcbc2cc04ac867b80635bf268596584..8baaa09a465dc7e70c67a9ffa485d07d106877c3 100644
--- a/tools/dom/templates/immutable_list_mixin.darttemplate
+++ b/tools/dom/templates/immutable_list_mixin.darttemplate
@@ -143,6 +143,14 @@ $endif
throw new UnsupportedError("Cannot add to immutable List.");
}
+ void insertAll(int index, Iterable<$E> iterable) {
+ throw new UnsupportedError("Cannot add to immutable List.");
+ }
+
+ void setAll(int index, Iterable<$E> iterable) {
+ throw new UnsupportedError("Cannot modify an immutable List.");
+ }
+
$E removeAt(int pos) {
throw new UnsupportedError("Cannot remove from immutable List.");
}
@@ -171,6 +179,14 @@ $endif
throw new UnsupportedError("Cannot removeRange on immutable List.");
}
+ void replaceRange(int start, int end, Iterable<$E> iterable) {
+ throw new UnsupportedError("Cannot modify an immutable List.");
+ }
+
+ void fillRange(int start, int end, [$E fillValue]) {
+ throw new UnsupportedError("Cannot modify an immutable List.");
+ }
+
Iterable<$E> getRange(int start, int end) =>
IterableMixinWorkaround.getRangeList(this, start, end);
« sdk/lib/core/list.dart ('K') | « tools/dom/templates/html/impl/impl_Node.darttemplate ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698