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

Unified Diff: pkg/polymer_expressions/lib/visitor.dart

Issue 139903008: List literals in polymer_expressions (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 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
Index: pkg/polymer_expressions/lib/visitor.dart
diff --git a/pkg/polymer_expressions/lib/visitor.dart b/pkg/polymer_expressions/lib/visitor.dart
index cf2626e6ec45837f7531a1a131e335d5b43047bf..08a6a022aac7498305e659c6daf013dedf6ceadd 100644
--- a/pkg/polymer_expressions/lib/visitor.dart
+++ b/pkg/polymer_expressions/lib/visitor.dart
@@ -14,6 +14,7 @@ abstract class Visitor {
visitIndex(Index i);
visitInvoke(Invoke i);
visitLiteral(Literal l);
+ visitListLiteral(ListLiteral l);
visitMapLiteral(MapLiteral l);
visitMapLiteralEntry(MapLiteralEntry l);
visitIdentifier(Identifier i);
@@ -56,6 +57,13 @@ abstract class RecursiveVisitor extends Visitor {
visitLiteral(Literal l) => visitExpression(l);
+ visitListLiteral(ListLiteral l) {
+ for (var i in l.items) {
+ visit(i);
+ }
+ visitExpression(l);
+ }
+
visitMapLiteral(MapLiteral l) {
for (var e in l.entries) {
visit(e);

Powered by Google App Engine
This is Rietveld 408576698