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

Unified Diff: sdk/lib/_internal/compiler/implementation/compile_time_constants.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/compile_time_constants.dart
diff --git a/sdk/lib/_internal/compiler/implementation/compile_time_constants.dart b/sdk/lib/_internal/compiler/implementation/compile_time_constants.dart
index 8a21068dc5082109085d987f069c4878c05211d3..52e988ea9af1be5d4fd32e647b7eb79ec7344404 100644
--- a/sdk/lib/_internal/compiler/implementation/compile_time_constants.dart
+++ b/sdk/lib/_internal/compiler/implementation/compile_time_constants.dart
@@ -816,9 +816,9 @@ class ConstructorEvaluator extends CompileTimeConstantEvaluator {
Node node = parameter.node;
potentiallyCheckType(node, parameter, argument);
definitions[parameter] = argument;
- if (parameter.kind == ElementKind.FIELD_PARAMETER) {
- FieldParameterElement fieldParameterElement = parameter;
- updateFieldValue(node, fieldParameterElement.fieldElement, argument);
+ if (parameter.isInitializingFormal) {
+ InitializingFormalElement initializingFormal = parameter;
+ updateFieldValue(node, initializingFormal.fieldElement, argument);
}
});
}

Powered by Google App Engine
This is Rietveld 408576698