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

Unified Diff: sdk/lib/_internal/compiler/implementation/inferrer/type_graph_nodes.dart

Issue 392873002: Element-model refactoring. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Updated cf. comments. Created 6 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
Index: sdk/lib/_internal/compiler/implementation/inferrer/type_graph_nodes.dart
diff --git a/sdk/lib/_internal/compiler/implementation/inferrer/type_graph_nodes.dart b/sdk/lib/_internal/compiler/implementation/inferrer/type_graph_nodes.dart
index 4a1e4e94d30917d80d0cec7eac1bd6819b1bf122..1e5dbeade274ce8154d9c3fa281284427ff4f1cb 100644
--- a/sdk/lib/_internal/compiler/implementation/inferrer/type_graph_nodes.dart
+++ b/sdk/lib/_internal/compiler/implementation/inferrer/type_graph_nodes.dart
@@ -251,7 +251,7 @@ class ElementTypeInformation extends ApplyableTypeInformation {
factory ElementTypeInformation(Element element) {
var assignments = null;
if (element.enclosingElement.isInstanceMember &&
- (element.isParameter || element.isFieldParameter)) {
+ (element.isParameter || element.isInitializingFormal)) {
assignments = new ParameterAssignments();
}
return new ElementTypeInformation.internal(element, assignments);
@@ -321,7 +321,7 @@ class ElementTypeInformation extends ApplyableTypeInformation {
}
if (element.isField ||
element.isParameter ||
- element.isFieldParameter) {
+ element.isInitializingFormal) {
if (!inferrer.compiler.backend.canBeUsedForGlobalOptimizations(element)) {
// Do not infer types for fields and parameters being assigned
// by synthesized calls.
@@ -370,7 +370,7 @@ class ElementTypeInformation extends ApplyableTypeInformation {
TypeGraphInferrerEngine inferrer) {
Compiler compiler = inferrer.compiler;
// Parameters are being explicitly checked in the method.
- if (element.isParameter || element.isFieldParameter) return mask;
+ if (element.isParameter || element.isInitializingFormal) return mask;
if (!compiler.trustTypeAnnotations && !compiler.enableTypeAssertions) {
return mask;
}

Powered by Google App Engine
This is Rietveld 408576698