Index: pkg/front_end/lib/src/fasta/type_inference/type_inferrer.dart |
diff --git a/pkg/front_end/lib/src/fasta/type_inference/type_inferrer.dart b/pkg/front_end/lib/src/fasta/type_inference/type_inferrer.dart |
index 73c98cc0ed765e42978d4ff155b6b30106497f2d..1d39d0e0e14f9e9fa3092fc7b919dfc3ef829355 100644 |
--- a/pkg/front_end/lib/src/fasta/type_inference/type_inferrer.dart |
+++ b/pkg/front_end/lib/src/fasta/type_inference/type_inferrer.dart |
@@ -454,9 +454,10 @@ abstract class TypeInferrerImpl<S, E, V, F> extends TypeInferrer<S, E, V, F> { |
Substitution.fromPairs(memberTypeParameters, inferredTypes); |
formalTypes = []; |
actualTypes = []; |
- } else if (explicitTypeArguments != null) { |
+ } else if (explicitTypeArguments != null && |
+ memberTypeParameters.length == explicitTypeArguments.length) { |
substitution = |
- Substitution.fromPairs(memberTypeParameters, inferredTypes); |
+ Substitution.fromPairs(memberTypeParameters, explicitTypeArguments); |
} |
int i = 0; |
forEachArgument((name, expression) { |