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

Unified Diff: pkg/compiler/lib/src/inferrer/inferrer_engine.dart

Issue 2619243002: Make .enclosingClass always return the declaration (Closed)
Patch Set: Add comment. Created 3 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/compiler/lib/src/inferrer/inferrer_engine.dart
diff --git a/pkg/compiler/lib/src/inferrer/inferrer_engine.dart b/pkg/compiler/lib/src/inferrer/inferrer_engine.dart
index 049a86a798ea10a815a36fea9f6dc6b306301c2b..4623b5c1b5ab3ed65c15bda27b8075aa3c670681 100644
--- a/pkg/compiler/lib/src/inferrer/inferrer_engine.dart
+++ b/pkg/compiler/lib/src/inferrer/inferrer_engine.dart
@@ -834,7 +834,7 @@ class InferrerEngine {
// If this class has a 'call' method then we have essentially created a
// closure here. Register it as such so that it is traced.
if (selector != null && selector.isCall && callee.isConstructor) {
- ClassElement cls = callee.enclosingClass.declaration;
+ ClassElement cls = callee.enclosingClass;
if (cls.callType != null) {
types.allocatedClosures.add(info);
}

Powered by Google App Engine
This is Rietveld 408576698