| Index: pkg/front_end/lib/src/fasta/type_inference/type_schema_environment.dart
|
| diff --git a/pkg/front_end/lib/src/fasta/type_inference/type_schema_environment.dart b/pkg/front_end/lib/src/fasta/type_inference/type_schema_environment.dart
|
| index 32d872cc7e3401920322f94c57ed3ad3a40d323f..16beabb7bf8e4b37d3da6afa9aebed4077fb3836 100644
|
| --- a/pkg/front_end/lib/src/fasta/type_inference/type_schema_environment.dart
|
| +++ b/pkg/front_end/lib/src/fasta/type_inference/type_schema_environment.dart
|
| @@ -226,6 +226,13 @@ class TypeSchemaEnvironment extends TypeEnvironment {
|
| List<DartType> actualTypes,
|
| DartType returnContextType,
|
| List<DartType> inferredTypes) {
|
| + if (returnContextType is DynamicType) {
|
| + // Analyzer treats a type context of `dynamic` as equivalent to an empty
|
| + // context. TODO(paulberry): this is not spec'ed anywhere; do we still
|
| + // want to do this?
|
| + returnContextType = null;
|
| + }
|
| +
|
| if (typeParametersToInfer.isEmpty) {
|
| return;
|
| }
|
|
|