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

Unified Diff: pkg/compiler/lib/src/elements/modelx.dart

Issue 1382313002: dart2js: set effective target for patched constructors (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 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
Index: pkg/compiler/lib/src/elements/modelx.dart
diff --git a/pkg/compiler/lib/src/elements/modelx.dart b/pkg/compiler/lib/src/elements/modelx.dart
index f1d4c5bb04fe6dd1ea4afdecb656901fe57a8e12..1073644d1f6d21773cc9eff098e14226d270c438 100644
--- a/pkg/compiler/lib/src/elements/modelx.dart
+++ b/pkg/compiler/lib/src/elements/modelx.dart
@@ -2203,7 +2203,11 @@ abstract class ConstructorElementX extends FunctionElementX
return immediateRedirectionTarget;
}
assert(!isRedirectingFactory || internalEffectiveTarget != null);
- return isRedirectingFactory ? internalEffectiveTarget : this;
+ if (isRedirectingFactory) return internalEffectiveTarget;
+ if (isPatched) {
Johnni Winther 2015/10/06 10:38:14 Why is this needed?
Harry Terkelsen 2015/10/12 18:17:44 There are targets that are patched but are not red
+ return internalEffectiveTarget ?? this;
+ }
+ return this;
}
InterfaceType computeEffectiveTargetType(InterfaceType newType) {
« no previous file with comments | « no previous file | pkg/compiler/lib/src/resolution/resolution.dart » ('j') | pkg/compiler/lib/src/resolution/resolution.dart » ('J')

Powered by Google App Engine
This is Rietveld 408576698