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

Unified Diff: client/html/release/htmlimpl.dart

Side-by-side diff isn't available for this file because of its large size.
Issue 8953001: Cleaner and more correct fix for _ChildrenNodeList#forEach. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 9 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
Download patch
« no previous file with comments | « no previous file | client/html/src/NodeWrappingImplementation.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: client/html/release/htmlimpl.dart
diff --git a/client/html/release/htmlimpl.dart b/client/html/release/htmlimpl.dart
index 13dc71d298c18f4d6942442281459ac2babd1a70..64ec2916bdb15650d21860e1afa1257bd08e923d 100644
--- a/client/html/release/htmlimpl.dart
+++ b/client/html/release/htmlimpl.dart
@@ -23890,11 +23890,7 @@ class _ChildrenNodeList implements NodeList {
return LevelDom.wrapNode(_node.firstChild);
}
- void forEach(void f(Node element)) {
- for (int i = 0, len = _childNodes.length; i < len; i++) {
- f(LevelDom.wrapNode(_childNodes[i]));
- }
- }
+ void forEach(void f(Node element)) => _toList().forEach(f);
Collection<Node> filter(bool f(Node element)) {
List<Node> output = new List<Node>();
« no previous file with comments | « no previous file | client/html/src/NodeWrappingImplementation.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698