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

Unified Diff: pkg/analyzer2dart/lib/src/semantic_visitor.dart

Issue 669673006: Add SExpression test and share tests between dart2dart and analyzer2dart. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Updated cf. comments. Created 6 years, 2 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 | « pkg/analyzer2dart/lib/src/cps_generator.dart ('k') | pkg/analyzer2dart/test/end2end_data.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analyzer2dart/lib/src/semantic_visitor.dart
diff --git a/pkg/analyzer2dart/lib/src/semantic_visitor.dart b/pkg/analyzer2dart/lib/src/semantic_visitor.dart
index b0b955c132cb234cce1ab26861f42858c38b3019..f16b0c2ab80c031c7a992d0e9f1100cf96fb857d 100644
--- a/pkg/analyzer2dart/lib/src/semantic_visitor.dart
+++ b/pkg/analyzer2dart/lib/src/semantic_visitor.dart
@@ -77,6 +77,10 @@ abstract class SemanticVisitor<R> extends RecursiveAstVisitor<R> {
node.target.accept(this);
}
node.argumentList.accept(this);
+ return handleMethodInvocation(node);
+ }
+
+ R handleMethodInvocation(MethodInvocation node) {
AccessSemantics semantics = classifyMethodInvocation(node);
switch (semantics.kind) {
case AccessKind.DYNAMIC:
@@ -105,12 +109,20 @@ abstract class SemanticVisitor<R> extends RecursiveAstVisitor<R> {
if (node.target != null) {
node.target.accept(this);
}
+ return handlePropertyAccess(node);
+ }
+
+ R handlePropertyAccess(PropertyAccess node) {
return _handlePropertyAccess(node, classifyPropertyAccess(node));
}
@override
R visitPrefixedIdentifier(PrefixedIdentifier node) {
node.prefix.accept(this);
+ return handlePrefixedIdentifier(node);
+ }
+
+ R handlePrefixedIdentifier(PrefixedIdentifier node) {
return _handlePropertyAccess(node, classifyPrefixedIdentifier(node));
}
« no previous file with comments | « pkg/analyzer2dart/lib/src/cps_generator.dart ('k') | pkg/analyzer2dart/test/end2end_data.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698