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

Unified Diff: pkg/compiler/lib/src/js/template.dart

Issue 917033002: Redo "Steps towards making dart2js JS AST templates an indepentent library." (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 5 years, 10 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: pkg/compiler/lib/src/js/template.dart
diff --git a/pkg/compiler/lib/src/js/template.dart b/pkg/compiler/lib/src/js/template.dart
index f08fe5239b4847576277eea271795f175b51ecae..7740431fc05ed717483c4adbbc7e189beac6657e 100644
--- a/pkg/compiler/lib/src/js/template.dart
+++ b/pkg/compiler/lib/src/js/template.dart
@@ -2,7 +2,7 @@
// for details. All rights reserved. Use of this source code is governed by a
// BSD-style license that can be found in the LICENSE file.
-part of js;
+part of js_ast;
class TemplateManager {
Map<String, Template> expressionTemplates = new Map<String, Template>();
@@ -499,8 +499,6 @@ class InstantiatorGeneratorVisitor implements NodeVisitor<Instantiator> {
Instantiator visitLiteralStatement(LiteralStatement node) =>
TODO('visitLiteralStatement');
- Instantiator visitBlob(Blob node) =>
- TODO('visitBlob');
Instantiator visitLiteralExpression(LiteralExpression node) =>
TODO('visitLiteralExpression');
@@ -709,12 +707,12 @@ class InstantiatorGeneratorVisitor implements NodeVisitor<Instantiator> {
}
/**
- * InterpolatedNodeAnalysis extract [InterpolatedNode]s from AST.
+ * InterpolatedNodeAnalysis determines which AST trees contain
+ * [InterpolatedNode]s, and the names of the named interpolated nodes.
*/
class InterpolatedNodeAnalysis extends BaseVisitor {
- final Setlet<Node> containsInterpolatedNode = new Setlet<Node>();
- final List<InterpolatedNode> interpolatedNodes = <InterpolatedNode>[];
- final Setlet<String> holeNames = new Setlet<String>();
+ final Set<Node> containsInterpolatedNode = new Set<Node>();
+ final Set<String> holeNames = new Set<String>();
int count = 0;
InterpolatedNodeAnalysis();
@@ -734,7 +732,6 @@ class InterpolatedNodeAnalysis extends BaseVisitor {
}
visitInterpolatedNode(InterpolatedNode node) {
- interpolatedNodes.add(node);
containsInterpolatedNode.add(node);
if (node.isNamed) holeNames.add(node.nameOrPosition);
++count;
« no previous file with comments | « pkg/compiler/lib/src/js/rewrite_async.dart ('k') | pkg/compiler/lib/src/js_emitter/old_emitter/emitter.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698