Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: utils/dumpast.js

Issue 29350140: Issue 4353 - Remove non standard for each syntax (Closed)
Patch Set: Created Aug. 24, 2016, 11:08 a.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: utils/dumpast.js
diff --git a/utils/dumpast.js b/utils/dumpast.js
index f356345ab2ffe5df497fa89fdc3a4d742771e3e1..af860de655a9db7d3333547ebb1f4c476bccd7ef 100644
--- a/utils/dumpast.js
+++ b/utils/dumpast.js
@@ -18,7 +18,7 @@ function dump_ast(ast, prefix) {
str += ast.line + ":" + ast.column;
_print(str);
prefix += " ";
- for each (let kid in ast.kids) {
+ for (let kid of ast.kids) {
dump_ast(kid, prefix);
}
}
@@ -65,7 +65,7 @@ function dump_trueast(ast, prefix) {
let val = ast[key];
if (val instanceof Array) {
_print(prefix + " + " + key + ": [");
- for each (let kind in val) {
+ for (let kind of val) {
dump_trueast(kind, prefix + " ");
}
_print(prefix + " ]");
« scripts/decompile.js ('K') | « utils/comments.js ('k') | utils/jstypes.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld