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

Unified Diff: client/html/src/_Collections.dart

Issue 9167006: Support map in generated dart:html files. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 11 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 | « client/html/release/htmlimpl.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: client/html/src/_Collections.dart
diff --git a/client/html/src/_Collections.dart b/client/html/src/_Collections.dart
index 3a3d3c5a0fec60453582eb2ff61d7b82c222d250..785e669fd2a927b99190edfc782d6ea6bee55d7b 100644
--- a/client/html/src/_Collections.dart
+++ b/client/html/src/_Collections.dart
@@ -14,6 +14,15 @@ class _Collections {
}
}
+ static List map(Iterable<Object> source,
+ List<Object> destination,
+ f(o)) {
+ for (final e in source) {
+ destination.add(f(e));
+ }
+ return destination;
+ }
+
static bool some(Iterable<Object> iterable, bool f(Object o)) {
for (final e in iterable) {
if (f(e)) return true;
« no previous file with comments | « client/html/release/htmlimpl.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698