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

Unified Diff: sdk/lib/_internal/compiler/implementation/resolution/members.dart

Issue 12389025: Do not register typechecks against type variables of typedefs. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Add a helper. Created 7 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
« no previous file with comments | « sdk/lib/_internal/compiler/implementation/enqueue.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sdk/lib/_internal/compiler/implementation/resolution/members.dart
diff --git a/sdk/lib/_internal/compiler/implementation/resolution/members.dart b/sdk/lib/_internal/compiler/implementation/resolution/members.dart
index 03509e799d557d2d30e3bf41d45c3198dda401b1..b19582be75a90cf9e023e1fe24eaae032fbe82bb 100644
--- a/sdk/lib/_internal/compiler/implementation/resolution/members.dart
+++ b/sdk/lib/_internal/compiler/implementation/resolution/members.dart
@@ -1747,7 +1747,9 @@ class ResolverVisitor extends CommonResolverVisitor<Element> {
DartType type = resolveTypeAnnotation(node);
if (type != null) {
if (inCheckContext) {
- compiler.enqueuer.resolution.registerIsCheck(type);
+ if (!Types.isTypeVariableOfTypedef(type)) {
+ compiler.enqueuer.resolution.registerIsCheck(type);
+ }
}
return type.element;
}
@@ -2568,7 +2570,9 @@ class ResolverVisitor extends CommonResolverVisitor<Element> {
onFailure: report, whenResolved: useType);
if (type == null) return null;
if (inCheckContext) {
- compiler.enqueuer.resolution.registerIsCheck(type);
+ if (!Types.isTypeVariableOfTypedef(type)) {
+ compiler.enqueuer.resolution.registerIsCheck(type);
+ }
}
if (typeRequired || inCheckContext) {
if (type is InterfaceType) {
« no previous file with comments | « sdk/lib/_internal/compiler/implementation/enqueue.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698