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

Unified Diff: tool/input_sdk/lib/core/list.dart

Issue 1939093003: List.unmodifiable (Closed) Base URL: https://github.com/dart-lang/dev_compiler@master
Patch Set: /*<E>*/ Created 4 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
« no previous file with comments | « lib/runtime/dart_sdk.js ('k') | tool/input_sdk/lib/internal/list.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tool/input_sdk/lib/core/list.dart
diff --git a/tool/input_sdk/lib/core/list.dart b/tool/input_sdk/lib/core/list.dart
index 3b8930a8dae9c561fc7f353388cf4b31b6bd0813..d89b5db0c5aa71d338baaf9244d0366bcc7360ef 100644
--- a/tool/input_sdk/lib/core/list.dart
+++ b/tool/input_sdk/lib/core/list.dart
@@ -122,6 +122,17 @@ abstract class List<E> implements Iterable<E> {
}
/**
+ * Creates an unmodifiable list containing all [elements].
+ *
+ * The [Iterator] of [elements] provides the order of the elements.
+ *
+ * An unmodifiable list cannot have its length or elements changed.
+ * If the elements are themselves immutable, then the resulting list
+ * is also immutable.
+ */
+ external factory List.unmodifiable(Iterable elements);
+
+ /**
* Returns the object at the given [index] in the list
* or throws a [RangeError] if [index] is out of bounds.
*/
« no previous file with comments | « lib/runtime/dart_sdk.js ('k') | tool/input_sdk/lib/internal/list.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698