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

Unified Diff: pkg/compiler/lib/src/resolution/resolution.dart

Issue 2118763002: Revert "Handle fields with initializers in constant constructors." (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Created 4 years, 6 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/resolution/resolution.dart
diff --git a/pkg/compiler/lib/src/resolution/resolution.dart b/pkg/compiler/lib/src/resolution/resolution.dart
index f77519078554fdd3435b4a9270104b57fe86c583..05e1cf08270a8adf530cfb01eb1b98806ccbd360 100644
--- a/pkg/compiler/lib/src/resolution/resolution.dart
+++ b/pkg/compiler/lib/src/resolution/resolution.dart
@@ -53,7 +53,6 @@ import 'class_members.dart' show MembersCreator;
import 'constructors.dart';
import 'members.dart';
import 'registry.dart';
-import 'resolution_result.dart';
import 'scope.dart' show MutableScope;
import 'signatures.dart';
import 'tree_elements.dart';
@@ -388,10 +387,7 @@ class ResolverTask extends CompilerTask {
if (initializer != null) {
// TODO(johnniwinther): Avoid analyzing initializers if
// [Compiler.analyzeSignaturesOnly] is set.
- ResolutionResult result = visitor.visit(initializer);
- if (result.isConstant) {
- element.constant = result.constant;
- }
+ visitor.visit(initializer);
} else if (modifiers.isConst) {
reporter.reportErrorMessage(
element, MessageKind.CONST_WITHOUT_INITIALIZER);
« no previous file with comments | « pkg/compiler/lib/src/resolution/constructors.dart ('k') | tests/compiler/dart2js/constant_expression_evaluate_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698