Index: pkg/analyzer/test/src/task/dart_test.dart |
diff --git a/pkg/analyzer/test/src/task/dart_test.dart b/pkg/analyzer/test/src/task/dart_test.dart |
index 4036ee2f1e26428930c9095736faf6385fa61035..cfbfc2e06cd2308d37125ff33969a5cedc7348e0 100644 |
--- a/pkg/analyzer/test/src/task/dart_test.dart |
+++ b/pkg/analyzer/test/src/task/dart_test.dart |
@@ -1495,6 +1495,21 @@ const d = a; |
'''); |
} |
+ test_const_constructor_calls_implicit_super_constructor_implicitly() { |
+ // Note: the situation below is a compile-time error (since the synthetic |
+ // constructor for Base is non-const), but we need to handle it without |
+ // throwing an exception. |
+ EvaluationResultImpl evaluationResult = _computeTopLevelVariableConstValue( |
+ 'x', ''' |
+class Base {} |
+class Derived extends Base { |
+ const Derived(); |
+} |
+const x = const Derived(); |
+'''); |
+ expect(evaluationResult, isNotNull); |
+ } |
+ |
test_dependency() { |
EvaluationResultImpl evaluationResult = _computeTopLevelVariableConstValue( |
'x', ''' |