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

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

Issue 2979813002: Use entities in the TypeSystem interface. (Closed)
Patch Set: Created 3 years, 5 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 | « no previous file | pkg/compiler/lib/src/inferrer/closure_tracer.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/compiler/lib/src/inferrer/builder.dart
diff --git a/pkg/compiler/lib/src/inferrer/builder.dart b/pkg/compiler/lib/src/inferrer/builder.dart
index c9c92be952b9e157a5562d852bdbc135809b2d3f..125472e1ce9d51a877ed6b597ce2b489fc9901c1 100644
--- a/pkg/compiler/lib/src/inferrer/builder.dart
+++ b/pkg/compiler/lib/src/inferrer/builder.dart
@@ -744,10 +744,13 @@ class ElementGraphBuilder extends ast.Visitor<TypeInformation>
ast.Node exception = node.exception;
if (exception != null) {
ResolutionDartType type = elements.getType(node.type);
- TypeInformation mask =
- type == null || type.treatAsDynamic || type.isTypeVariable
- ? types.dynamicType
- : types.nonNullSubtype(type.element);
+ TypeInformation mask;
+ if (type == null || type.treatAsDynamic || type.isTypeVariable) {
+ mask = types.dynamicType;
+ } else {
+ ResolutionInterfaceType interfaceType = type;
+ mask = types.nonNullSubtype(interfaceType.element);
+ }
locals.update(elements[exception], mask, node);
}
ast.Node trace = node.trace;
« no previous file with comments | « no previous file | pkg/compiler/lib/src/inferrer/closure_tracer.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698