Add error code ArgumentTypeNotAssignable to improve messaging (issue 33712)

Change-Id: I9a6e039efdf396f838ae99926877658f5570e380
Reviewed-on: https://dart-review.googlesource.com/63960
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
diff --git a/pkg/analyzer/test/generated/checked_mode_compile_time_error_code_kernel_test.dart b/pkg/analyzer/test/generated/checked_mode_compile_time_error_code_kernel_test.dart
index 6cd4ceb..7ffb604 100644
--- a/pkg/analyzer/test/generated/checked_mode_compile_time_error_code_kernel_test.dart
+++ b/pkg/analyzer/test/generated/checked_mode_compile_time_error_code_kernel_test.dart
@@ -38,13 +38,6 @@
 
   @failingTest
   @override
-  test_fieldFormalParameterAssignableToField_typedef() async {
-    // Expected 1 errors of type StaticWarningCode.ARGUMENT_TYPE_NOT_ASSIGNABLE, found 0
-    await super.test_fieldFormalParameterAssignableToField_typedef();
-  }
-
-  @failingTest
-  @override
   test_fieldFormalParameterNotAssignableToField() async {
     // Expected 1 errors of type CheckedModeCompileTimeErrorCode.CONST_CONSTRUCTOR_PARAM_TYPE_MISMATCH, found 0;
     //          1 errors of type StaticWarningCode.ARGUMENT_TYPE_NOT_ASSIGNABLE, found 0
diff --git a/pkg/analyzer/test/generated/hint_code_kernel_test.dart b/pkg/analyzer/test/generated/hint_code_kernel_test.dart
index b99033d..bfc95d5 100644
--- a/pkg/analyzer/test/generated/hint_code_kernel_test.dart
+++ b/pkg/analyzer/test/generated/hint_code_kernel_test.dart
@@ -57,20 +57,6 @@
 
   @failingTest
   @override
-  test_argumentTypeNotAssignable_functionType() async {
-    // Expected 1 errors of type HintCode.ARGUMENT_TYPE_NOT_ASSIGNABLE, found 0
-    return super.test_argumentTypeNotAssignable_functionType();
-  }
-
-  @failingTest
-  @override
-  test_argumentTypeNotAssignable_type() async {
-    // Expected 1 errors of type HintCode.ARGUMENT_TYPE_NOT_ASSIGNABLE, found 0
-    return super.test_argumentTypeNotAssignable_type();
-  }
-
-  @failingTest
-  @override
   test_deprecatedAnnotationUse_call() async {
     // Expected 1 errors of type HintCode.DEPRECATED_MEMBER_USE, found 0
     return super.test_deprecatedAnnotationUse_call();
diff --git a/pkg/analyzer/test/generated/static_warning_code_kernel_test.dart b/pkg/analyzer/test/generated/static_warning_code_kernel_test.dart
index 3bb8b7a..f9fd7bc 100644
--- a/pkg/analyzer/test/generated/static_warning_code_kernel_test.dart
+++ b/pkg/analyzer/test/generated/static_warning_code_kernel_test.dart
@@ -126,48 +126,6 @@
   @override
   @failingTest
   @potentialAnalyzerProblem
-  test_argumentTypeNotAssignable_ambiguousClassName() async {
-    return super.test_argumentTypeNotAssignable_ambiguousClassName();
-  }
-
-  @override
-  @failingTest
-  @potentialAnalyzerProblem
-  test_argumentTypeNotAssignable_annotation_namedConstructor() async {
-    return super.test_argumentTypeNotAssignable_annotation_namedConstructor();
-  }
-
-  @override
-  @failingTest
-  @potentialAnalyzerProblem
-  test_argumentTypeNotAssignable_annotation_unnamedConstructor() async {
-    return super.test_argumentTypeNotAssignable_annotation_unnamedConstructor();
-  }
-
-  @override
-  @failingTest
-  @potentialAnalyzerProblem
-  test_argumentTypeNotAssignable_binary() async {
-    return super.test_argumentTypeNotAssignable_binary();
-  }
-
-  @override
-  @failingTest
-  test_argumentTypeNotAssignable_call() {
-    // UnimplementedError: TODO(paulberry): resynthesize generic typedef
-    return super.test_argumentTypeNotAssignable_call();
-  }
-
-  @override
-  @failingTest
-  @potentialAnalyzerProblem
-  test_argumentTypeNotAssignable_cascadeSecond() async {
-    return super.test_argumentTypeNotAssignable_cascadeSecond();
-  }
-
-  @override
-  @failingTest
-  @potentialAnalyzerProblem
   test_argumentTypeNotAssignable_const() async {
     return super.test_argumentTypeNotAssignable_const();
   }
@@ -182,120 +140,6 @@
   @override
   @failingTest
   @potentialAnalyzerProblem
-  test_argumentTypeNotAssignable_functionExpressionInvocation_required() async {
-    return super
-        .test_argumentTypeNotAssignable_functionExpressionInvocation_required();
-  }
-
-  @override
-  @failingTest
-  @potentialAnalyzerProblem
-  test_argumentTypeNotAssignable_index() async {
-    return super.test_argumentTypeNotAssignable_index();
-  }
-
-  @override
-  @failingTest
-  @potentialAnalyzerProblem
-  test_argumentTypeNotAssignable_invocation_callParameter() async {
-    return super.test_argumentTypeNotAssignable_invocation_callParameter();
-  }
-
-  @override
-  @failingTest
-  @potentialAnalyzerProblem
-  test_argumentTypeNotAssignable_invocation_callVariable() async {
-    return super.test_argumentTypeNotAssignable_invocation_callVariable();
-  }
-
-  @override
-  @failingTest
-  @potentialAnalyzerProblem
-  test_argumentTypeNotAssignable_invocation_functionParameter() async {
-    return super.test_argumentTypeNotAssignable_invocation_functionParameter();
-  }
-
-  @override
-  @failingTest
-  @potentialAnalyzerProblem
-  test_argumentTypeNotAssignable_invocation_functionParameter_generic() async {
-    return super
-        .test_argumentTypeNotAssignable_invocation_functionParameter_generic();
-  }
-
-  @override
-  @failingTest
-  @potentialAnalyzerProblem
-  test_argumentTypeNotAssignable_invocation_generic() async {
-    return super.test_argumentTypeNotAssignable_invocation_generic();
-  }
-
-  @override
-  @failingTest
-  @potentialAnalyzerProblem
-  test_argumentTypeNotAssignable_invocation_named() async {
-    return super.test_argumentTypeNotAssignable_invocation_named();
-  }
-
-  @override
-  @failingTest
-  @potentialAnalyzerProblem
-  test_argumentTypeNotAssignable_invocation_optional() async {
-    return super.test_argumentTypeNotAssignable_invocation_optional();
-  }
-
-  @override
-  @failingTest
-  @potentialAnalyzerProblem
-  test_argumentTypeNotAssignable_invocation_required() async {
-    return super.test_argumentTypeNotAssignable_invocation_required();
-  }
-
-  @override
-  @failingTest
-  @potentialAnalyzerProblem
-  test_argumentTypeNotAssignable_invocation_typedef_generic() async {
-    return super.test_argumentTypeNotAssignable_invocation_typedef_generic();
-  }
-
-  @override
-  @failingTest
-  @potentialAnalyzerProblem
-  test_argumentTypeNotAssignable_invocation_typedef_local() async {
-    return super.test_argumentTypeNotAssignable_invocation_typedef_local();
-  }
-
-  @override
-  @failingTest
-  @potentialAnalyzerProblem
-  test_argumentTypeNotAssignable_invocation_typedef_parameter() async {
-    return super.test_argumentTypeNotAssignable_invocation_typedef_parameter();
-  }
-
-  @override
-  @failingTest
-  @potentialAnalyzerProblem
-  test_argumentTypeNotAssignable_new_generic() async {
-    return super.test_argumentTypeNotAssignable_new_generic();
-  }
-
-  @override
-  @failingTest
-  @potentialAnalyzerProblem
-  test_argumentTypeNotAssignable_new_optional() async {
-    return super.test_argumentTypeNotAssignable_new_optional();
-  }
-
-  @override
-  @failingTest
-  @potentialAnalyzerProblem
-  test_argumentTypeNotAssignable_new_required() async {
-    return super.test_argumentTypeNotAssignable_new_required();
-  }
-
-  @override
-  @failingTest
-  @potentialAnalyzerProblem
   test_assignmentToClass() async {
     return super.test_assignmentToClass();
   }
diff --git a/pkg/front_end/lib/src/fasta/fasta_codes_generated.dart b/pkg/front_end/lib/src/fasta/fasta_codes_generated.dart
index 1f344b2..7242425 100644
--- a/pkg/front_end/lib/src/fasta/fasta_codes_generated.dart
+++ b/pkg/front_end/lib/src/fasta/fasta_codes_generated.dart
@@ -133,6 +133,46 @@
 // DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
 const Template<
     Message Function(
+        DartType _type,
+        DartType
+            _type2)> templateArgumentTypeNotAssignable = const Template<
+        Message Function(DartType _type,
+            DartType _type2)>(
+    messageTemplate:
+        r"""The argument type '#type' can't be assigned to the parameter type '#type2'.""",
+    tipTemplate:
+        r"""Try changing the type of the parameter, or casting the argument to '#type2'.""",
+    withArguments: _withArgumentsArgumentTypeNotAssignable);
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Code<Message Function(DartType _type, DartType _type2)>
+    codeArgumentTypeNotAssignable =
+    const Code<Message Function(DartType _type, DartType _type2)>(
+        "ArgumentTypeNotAssignable", templateArgumentTypeNotAssignable,
+        analyzerCode: "ARGUMENT_TYPE_NOT_ASSIGNABLE", dart2jsCode: "*ignored*");
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+Message _withArgumentsArgumentTypeNotAssignable(
+    DartType _type, DartType _type2) {
+  NameSystem nameSystem = new NameSystem();
+  StringBuffer buffer = new StringBuffer();
+  new Printer(buffer, syntheticNames: nameSystem).writeNode(_type);
+  String type = '$buffer';
+
+  buffer = new StringBuffer();
+  new Printer(buffer, syntheticNames: nameSystem).writeNode(_type2);
+  String type2 = '$buffer';
+
+  return new Message(codeArgumentTypeNotAssignable,
+      message:
+          """The argument type '${type}' can't be assigned to the parameter type '${type2}'.""",
+      tip: """Try changing the type of the parameter, or casting the argument to '${type2}'.""",
+      arguments: {'type': _type, 'type2': _type2});
+}
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Template<
+    Message Function(
         int
             codePoint)> templateAsciiControlCharacter = const Template<
         Message Function(int codePoint)>(
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 9a9c2f1..016092a 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
@@ -516,7 +516,8 @@
   /// [expectedType], and inserts an implicit downcast if appropriate.
   Expression ensureAssignable(DartType expectedType, DartType actualType,
       Expression expression, int fileOffset,
-      {bool isReturnFromAsync = false}) {
+      {bool isReturnFromAsync = false,
+      Template<Message Function(DartType, DartType)> template}) {
     assert(expectedType != null);
     expectedType = greatestClosure(coreTypes, expectedType);
 
@@ -579,8 +580,10 @@
     if (!typeSchemaEnvironment.isSubtypeOf(expectedType, actualType)) {
       // Error: not assignable.  Perform error recovery.
       var parent = expression.parent;
-      var errorNode = helper.wrapInCompileTimeError(expression,
-          templateInvalidAssignment.withArguments(actualType, expectedType));
+      var errorNode = helper.wrapInCompileTimeError(
+          expression,
+          (template ?? templateInvalidAssignment)
+              .withArguments(actualType, expectedType));
       parent?.replaceChild(expression, errorNode);
       return errorNode;
     } else {
@@ -1203,7 +1206,8 @@
               ? arguments.positional[i]
               : arguments.named[i - numPositionalArgs].value;
           ensureAssignable(
-              expectedType, actualType, expression, expression.fileOffset);
+              expectedType, actualType, expression, expression.fileOffset,
+              template: templateArgumentTypeNotAssignable);
         }
       }
     }
diff --git a/pkg/front_end/messages.status b/pkg/front_end/messages.status
index 2231cab..14000d1 100644
--- a/pkg/front_end/messages.status
+++ b/pkg/front_end/messages.status
@@ -13,6 +13,7 @@
 AmbiguousSupertypes/analyzerCode: Fail
 AmbiguousSupertypes/example: Fail
 AnnotationOnEnumConstant/example: Fail
+ArgumentTypeNotAssignable/example: Fail
 AssertAsExpression/analyzerCode: Fail
 AssertAsExpression/example: Fail
 AssertExtraneousArgument/analyzerCode: Fail
diff --git a/pkg/front_end/messages.yaml b/pkg/front_end/messages.yaml
index 1b16b06..6072285 100644
--- a/pkg/front_end/messages.yaml
+++ b/pkg/front_end/messages.yaml
@@ -2183,6 +2183,12 @@
   analyzerCode: EXTERNAL_CONSTRUCTOR_WITH_BODY
   dart2jsCode: "*ignored*"
 
+ArgumentTypeNotAssignable:
+  template: "The argument type '#type' can't be assigned to the parameter type '#type2'."
+  tip: "Try changing the type of the parameter, or casting the argument to '#type2'."
+  analyzerCode: ARGUMENT_TYPE_NOT_ASSIGNABLE
+  dart2jsCode: "*ignored*"
+
 InvalidAssignment:
   template: "A value of type '#type' can't be assigned to a variable of type '#type2'."
   tip: "Try changing the type of the left hand side, or casting the right hand side to '#type2'."
diff --git a/pkg/front_end/testcases/bug33298.dart.strong.expect b/pkg/front_end/testcases/bug33298.dart.strong.expect
index 5d1ae80..e1f9aaf 100644
--- a/pkg/front_end/testcases/bug33298.dart.strong.expect
+++ b/pkg/front_end/testcases/bug33298.dart.strong.expect
@@ -32,8 +32,8 @@
   core::List<core::String> list4 = <core::String>["a", "b", "c"].{core::Iterable::map}<core::String>(let final self::B<core::String> #t2 = b in #t2.==(null) ?{(core::String) → core::String} null : #t2.{self::B::call}).{core::Iterable::toList}();
   self::C c = new self::C::•();
   core::List<core::String> list5 = <core::String>["a", "b", "c"].{core::Iterable::map}<core::String>(c.{self::C::call}<core::String>).{core::Iterable::toList}();
-  core::List<core::String> list6 = <core::String>["a", "b", "c"].{core::Iterable::map}<dynamic>(let dynamic _ = null in let final dynamic #t3 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/bug33298.dart:28:44: Error: A value of type '<T extends dart.core::Object = dynamic>(#lib1::C::call::T) \u8594 #lib1::C::call::T' can't be assigned to a variable of type '(dart.core::String) \u8594 dynamic'.
-Try changing the type of the left hand side, or casting the right hand side to '(dart.core::String) \u8594 dynamic'.
+  core::List<core::String> list6 = <core::String>["a", "b", "c"].{core::Iterable::map}<dynamic>(let dynamic _ = null in let final dynamic #t3 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/bug33298.dart:28:44: Error: The argument type '<T extends dart.core::Object = dynamic>(#lib1::C::call::T) \u8594 #lib1::C::call::T' can't be assigned to the parameter type '(dart.core::String) \u8594 dynamic'.
+Try changing the type of the parameter, or casting the argument to '(dart.core::String) \u8594 dynamic'.
   List<String> list6 = ['a', 'b', 'c'].map(c).toList();
                                            ^" in let final dynamic #t4 = let final self::C #t5 = c in #t5.==(null) ?{<T extends core::Object = dynamic>(self::C::call::T) → self::C::call::T} null : #t5.{self::C::call} in null).{core::Iterable::toList}() as{TypeError} core::List<core::String>;
 }
diff --git a/pkg/front_end/testcases/bug33298.dart.strong.transformed.expect b/pkg/front_end/testcases/bug33298.dart.strong.transformed.expect
index f0aa840..a14fb51 100644
--- a/pkg/front_end/testcases/bug33298.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/bug33298.dart.strong.transformed.expect
@@ -32,8 +32,8 @@
   core::List<core::String> list4 = <core::String>["a", "b", "c"].{core::Iterable::map}<core::String>(let final self::B<core::String> #t2 = b in #t2.==(null) ?{(core::String) → core::String} null : #t2.{self::B::call}).{core::Iterable::toList}();
   self::C c = new self::C::•();
   core::List<core::String> list5 = <core::String>["a", "b", "c"].{core::Iterable::map}<core::String>(c.{self::C::call}<core::String>).{core::Iterable::toList}();
-  core::List<core::String> list6 = <core::String>["a", "b", "c"].{core::Iterable::map}<dynamic>(let<BottomType> _ = null in let final dynamic #t3 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/bug33298.dart:28:44: Error: A value of type '<T extends dart.core::Object = dynamic>(#lib1::C::call::T) \u8594 #lib1::C::call::T' can't be assigned to a variable of type '(dart.core::String) \u8594 dynamic'.
-Try changing the type of the left hand side, or casting the right hand side to '(dart.core::String) \u8594 dynamic'.
+  core::List<core::String> list6 = <core::String>["a", "b", "c"].{core::Iterable::map}<dynamic>(let<BottomType> _ = null in let final dynamic #t3 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/bug33298.dart:28:44: Error: The argument type '<T extends dart.core::Object = dynamic>(#lib1::C::call::T) \u8594 #lib1::C::call::T' can't be assigned to the parameter type '(dart.core::String) \u8594 dynamic'.
+Try changing the type of the parameter, or casting the argument to '(dart.core::String) \u8594 dynamic'.
   List<String> list6 = ['a', 'b', 'c'].map(c).toList();
                                            ^" in let final <T extends core::Object = dynamic>(self::C::call::T) → self::C::call::T #t4 = let final self::C #t5 = c in #t5.==(null) ?{<T extends core::Object = dynamic>(self::C::call::T) → self::C::call::T} null : #t5.{self::C::call} in null).{core::Iterable::toList}() as{TypeError} core::List<core::String>;
 }
diff --git a/pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart.strong.expect b/pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart.strong.expect
index 9bf8892..32aa1b3 100644
--- a/pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart.strong.expect
@@ -65,18 +65,18 @@
                                                  ^" in let final dynamic #t4 = new self::A::named<dynamic, dynamic>(3, "hello") in null;
   }
   {
-    self::A<core::int, core::String> a0 = new self::A::•<core::int, core::String>(let dynamic _ = null in let final dynamic #t5 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:53:48: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+    self::A<core::int, core::String> a0 = new self::A::•<core::int, core::String>(let dynamic _ = null in let final dynamic #t5 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:53:48: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
         /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ \"hello\",
-                                               ^" in let final dynamic #t6 = "hello" in null, let dynamic _ = null in let final dynamic #t7 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:54:48: Error: A value of type 'dart.core::int' can't be assigned to a variable of type 'dart.core::String'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::String'.
+                                               ^" in let final dynamic #t6 = "hello" in null, let dynamic _ = null in let final dynamic #t7 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:54:48: Error: The argument type 'dart.core::int' can't be assigned to the parameter type 'dart.core::String'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::String'.
         /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 3);
                                                ^" in let final dynamic #t8 = 3 in null);
-    self::A<core::int, core::String> a1 = new self::A::named<core::int, core::String>(let dynamic _ = null in let final dynamic #t9 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:56:48: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+    self::A<core::int, core::String> a1 = new self::A::named<core::int, core::String>(let dynamic _ = null in let final dynamic #t9 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:56:48: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
         /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ \"hello\",
-                                               ^" in let final dynamic #t10 = "hello" in null, let dynamic _ = null in let final dynamic #t11 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:57:48: Error: A value of type 'dart.core::int' can't be assigned to a variable of type 'dart.core::String'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::String'.
+                                               ^" in let final dynamic #t10 = "hello" in null, let dynamic _ = null in let final dynamic #t11 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:57:48: Error: The argument type 'dart.core::int' can't be assigned to the parameter type 'dart.core::String'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::String'.
         /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 3);
                                                ^" in let final dynamic #t12 = 3 in null);
   }
@@ -95,18 +95,18 @@
                                               ^" in let final dynamic #t16 = new self::B::named<dynamic, dynamic>("hello", 3) in null;
   }
   {
-    self::A<core::int, core::String> a0 = new self::B::•<core::String, core::int>(let dynamic _ = null in let final dynamic #t17 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:72:48: Error: A value of type 'dart.core::int' can't be assigned to a variable of type 'dart.core::String'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::String'.
+    self::A<core::int, core::String> a0 = new self::B::•<core::String, core::int>(let dynamic _ = null in let final dynamic #t17 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:72:48: Error: The argument type 'dart.core::int' can't be assigned to the parameter type 'dart.core::String'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::String'.
         /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 3,
-                                               ^" in let final dynamic #t18 = 3 in null, let dynamic _ = null in let final dynamic #t19 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:73:48: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+                                               ^" in let final dynamic #t18 = 3 in null, let dynamic _ = null in let final dynamic #t19 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:73:48: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
         /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ \"hello\");
                                                ^" in let final dynamic #t20 = "hello" in null);
-    self::A<core::int, core::String> a1 = new self::B::named<core::String, core::int>(let dynamic _ = null in let final dynamic #t21 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:75:48: Error: A value of type 'dart.core::int' can't be assigned to a variable of type 'dart.core::String'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::String'.
+    self::A<core::int, core::String> a1 = new self::B::named<core::String, core::int>(let dynamic _ = null in let final dynamic #t21 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:75:48: Error: The argument type 'dart.core::int' can't be assigned to the parameter type 'dart.core::String'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::String'.
         /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 3,
-                                               ^" in let final dynamic #t22 = 3 in null, let dynamic _ = null in let final dynamic #t23 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:76:48: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+                                               ^" in let final dynamic #t22 = 3 in null, let dynamic _ = null in let final dynamic #t23 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:76:48: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
         /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ \"hello\");
                                                ^" in let final dynamic #t24 = "hello" in null);
   }
@@ -125,12 +125,12 @@
                                                       ^" in let final dynamic #t28 = new self::C::named<dynamic>(3) in null;
   }
   {
-    self::A<core::int, core::int> a0 = new self::C::•<core::int>(let dynamic _ = null in let final dynamic #t29 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:88:48: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+    self::A<core::int, core::int> a0 = new self::C::•<core::int>(let dynamic _ = null in let final dynamic #t29 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:88:48: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
         /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ \"hello\");
                                                ^" in let final dynamic #t30 = "hello" in null);
-    self::A<core::int, core::int> a1 = new self::C::named<core::int>(let dynamic _ = null in let final dynamic #t31 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:90:48: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+    self::A<core::int, core::int> a1 = new self::C::named<core::int>(let dynamic _ = null in let final dynamic #t31 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:90:48: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
         /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ \"hello\");
                                                ^" in let final dynamic #t32 = "hello" in null);
   }
@@ -149,12 +149,12 @@
                                               ^" in let final dynamic #t36 = new self::D::named<dynamic, dynamic>("hello") in null;
   }
   {
-    self::A<core::int, core::String> a0 = new self::D::•<dynamic, core::String>(let dynamic _ = null in let final dynamic #t37 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:105:48: Error: A value of type 'dart.core::int' can't be assigned to a variable of type 'dart.core::String'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::String'.
+    self::A<core::int, core::String> a0 = new self::D::•<dynamic, core::String>(let dynamic _ = null in let final dynamic #t37 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:105:48: Error: The argument type 'dart.core::int' can't be assigned to the parameter type 'dart.core::String'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::String'.
         /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 3);
                                                ^" in let final dynamic #t38 = 3 in null);
-    self::A<core::int, core::String> a1 = new self::D::named<dynamic, core::String>(let dynamic _ = null in let final dynamic #t39 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:107:48: Error: A value of type 'dart.core::int' can't be assigned to a variable of type 'dart.core::String'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::String'.
+    self::A<core::int, core::String> a1 = new self::D::named<dynamic, core::String>(let dynamic _ = null in let final dynamic #t39 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:107:48: Error: The argument type 'dart.core::int' can't be assigned to the parameter type 'dart.core::String'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::String'.
         /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 3);
                                                ^" in let final dynamic #t40 = 3 in null);
   }
@@ -172,15 +172,15 @@
                                                      ^" in let final dynamic #t44 = 3 in null]);
     self::A<core::int, core::String> a2 = new self::F::named<core::int, core::String>(3, "hello", 3, "hello");
     self::A<core::int, core::String> a3 = new self::F::named<core::int, core::String>(3, "hello");
-    self::A<core::int, core::String> a4 = new self::F::named<core::int, core::String>(3, "hello", let dynamic _ = null in let final dynamic #t45 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:129:48: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+    self::A<core::int, core::String> a4 = new self::F::named<core::int, core::String>(3, "hello", let dynamic _ = null in let final dynamic #t45 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:129:48: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
         /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ \"hello\",
-                                               ^" in let final dynamic #t46 = "hello" in null, let dynamic _ = null in let final dynamic #t47 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:130:48: Error: A value of type 'dart.core::int' can't be assigned to a variable of type 'dart.core::String'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::String'.
+                                               ^" in let final dynamic #t46 = "hello" in null, let dynamic _ = null in let final dynamic #t47 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:130:48: Error: The argument type 'dart.core::int' can't be assigned to the parameter type 'dart.core::String'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::String'.
         /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 3);
                                                ^" in let final dynamic #t48 = 3 in null);
-    self::A<core::int, core::String> a5 = new self::F::named<core::int, core::String>(3, "hello", let dynamic _ = null in let final dynamic #t49 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:134:48: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+    self::A<core::int, core::String> a5 = new self::F::named<core::int, core::String>(3, "hello", let dynamic _ = null in let final dynamic #t49 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:134:48: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
         /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ \"hello\");
                                                ^" in let final dynamic #t50 = "hello" in null);
   }
diff --git a/pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart.strong.transformed.expect
index 5de4511..9f54e17 100644
--- a/pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart.strong.transformed.expect
@@ -65,18 +65,18 @@
                                                  ^" in let final self::A<dynamic, dynamic> #t4 = new self::A::named<dynamic, dynamic>(3, "hello") in null;
   }
   {
-    self::A<core::int, core::String> a0 = new self::A::•<core::int, core::String>(let<BottomType> _ = null in let final dynamic #t5 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:53:48: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+    self::A<core::int, core::String> a0 = new self::A::•<core::int, core::String>(let<BottomType> _ = null in let final dynamic #t5 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:53:48: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
         /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ \"hello\",
-                                               ^" in let final core::String #t6 = "hello" in null, let<BottomType> _ = null in let final dynamic #t7 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:54:48: Error: A value of type 'dart.core::int' can't be assigned to a variable of type 'dart.core::String'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::String'.
+                                               ^" in let final core::String #t6 = "hello" in null, let<BottomType> _ = null in let final dynamic #t7 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:54:48: Error: The argument type 'dart.core::int' can't be assigned to the parameter type 'dart.core::String'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::String'.
         /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 3);
                                                ^" in let final core::int #t8 = 3 in null);
-    self::A<core::int, core::String> a1 = new self::A::named<core::int, core::String>(let<BottomType> _ = null in let final dynamic #t9 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:56:48: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+    self::A<core::int, core::String> a1 = new self::A::named<core::int, core::String>(let<BottomType> _ = null in let final dynamic #t9 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:56:48: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
         /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ \"hello\",
-                                               ^" in let final core::String #t10 = "hello" in null, let<BottomType> _ = null in let final dynamic #t11 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:57:48: Error: A value of type 'dart.core::int' can't be assigned to a variable of type 'dart.core::String'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::String'.
+                                               ^" in let final core::String #t10 = "hello" in null, let<BottomType> _ = null in let final dynamic #t11 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:57:48: Error: The argument type 'dart.core::int' can't be assigned to the parameter type 'dart.core::String'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::String'.
         /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 3);
                                                ^" in let final core::int #t12 = 3 in null);
   }
@@ -95,18 +95,18 @@
                                               ^" in let final self::B<dynamic, dynamic> #t16 = new self::B::named<dynamic, dynamic>("hello", 3) in null;
   }
   {
-    self::A<core::int, core::String> a0 = new self::B::•<core::String, core::int>(let<BottomType> _ = null in let final dynamic #t17 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:72:48: Error: A value of type 'dart.core::int' can't be assigned to a variable of type 'dart.core::String'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::String'.
+    self::A<core::int, core::String> a0 = new self::B::•<core::String, core::int>(let<BottomType> _ = null in let final dynamic #t17 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:72:48: Error: The argument type 'dart.core::int' can't be assigned to the parameter type 'dart.core::String'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::String'.
         /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 3,
-                                               ^" in let final core::int #t18 = 3 in null, let<BottomType> _ = null in let final dynamic #t19 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:73:48: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+                                               ^" in let final core::int #t18 = 3 in null, let<BottomType> _ = null in let final dynamic #t19 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:73:48: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
         /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ \"hello\");
                                                ^" in let final core::String #t20 = "hello" in null);
-    self::A<core::int, core::String> a1 = new self::B::named<core::String, core::int>(let<BottomType> _ = null in let final dynamic #t21 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:75:48: Error: A value of type 'dart.core::int' can't be assigned to a variable of type 'dart.core::String'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::String'.
+    self::A<core::int, core::String> a1 = new self::B::named<core::String, core::int>(let<BottomType> _ = null in let final dynamic #t21 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:75:48: Error: The argument type 'dart.core::int' can't be assigned to the parameter type 'dart.core::String'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::String'.
         /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 3,
-                                               ^" in let final core::int #t22 = 3 in null, let<BottomType> _ = null in let final dynamic #t23 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:76:48: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+                                               ^" in let final core::int #t22 = 3 in null, let<BottomType> _ = null in let final dynamic #t23 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:76:48: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
         /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ \"hello\");
                                                ^" in let final core::String #t24 = "hello" in null);
   }
@@ -125,12 +125,12 @@
                                                       ^" in let final self::C<dynamic> #t28 = new self::C::named<dynamic>(3) in null;
   }
   {
-    self::A<core::int, core::int> a0 = new self::C::•<core::int>(let<BottomType> _ = null in let final dynamic #t29 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:88:48: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+    self::A<core::int, core::int> a0 = new self::C::•<core::int>(let<BottomType> _ = null in let final dynamic #t29 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:88:48: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
         /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ \"hello\");
                                                ^" in let final core::String #t30 = "hello" in null);
-    self::A<core::int, core::int> a1 = new self::C::named<core::int>(let<BottomType> _ = null in let final dynamic #t31 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:90:48: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+    self::A<core::int, core::int> a1 = new self::C::named<core::int>(let<BottomType> _ = null in let final dynamic #t31 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:90:48: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
         /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ \"hello\");
                                                ^" in let final core::String #t32 = "hello" in null);
   }
@@ -149,12 +149,12 @@
                                               ^" in let final self::D<dynamic, dynamic> #t36 = new self::D::named<dynamic, dynamic>("hello") in null;
   }
   {
-    self::A<core::int, core::String> a0 = new self::D::•<dynamic, core::String>(let<BottomType> _ = null in let final dynamic #t37 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:105:48: Error: A value of type 'dart.core::int' can't be assigned to a variable of type 'dart.core::String'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::String'.
+    self::A<core::int, core::String> a0 = new self::D::•<dynamic, core::String>(let<BottomType> _ = null in let final dynamic #t37 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:105:48: Error: The argument type 'dart.core::int' can't be assigned to the parameter type 'dart.core::String'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::String'.
         /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 3);
                                                ^" in let final core::int #t38 = 3 in null);
-    self::A<core::int, core::String> a1 = new self::D::named<dynamic, core::String>(let<BottomType> _ = null in let final dynamic #t39 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:107:48: Error: A value of type 'dart.core::int' can't be assigned to a variable of type 'dart.core::String'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::String'.
+    self::A<core::int, core::String> a1 = new self::D::named<dynamic, core::String>(let<BottomType> _ = null in let final dynamic #t39 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:107:48: Error: The argument type 'dart.core::int' can't be assigned to the parameter type 'dart.core::String'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::String'.
         /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 3);
                                                ^" in let final core::int #t40 = 3 in null);
   }
@@ -172,15 +172,15 @@
                                                      ^" in let final core::int #t44 = 3 in null]);
     self::A<core::int, core::String> a2 = new self::F::named<core::int, core::String>(3, "hello", 3, "hello");
     self::A<core::int, core::String> a3 = new self::F::named<core::int, core::String>(3, "hello");
-    self::A<core::int, core::String> a4 = new self::F::named<core::int, core::String>(3, "hello", let<BottomType> _ = null in let final dynamic #t45 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:129:48: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+    self::A<core::int, core::String> a4 = new self::F::named<core::int, core::String>(3, "hello", let<BottomType> _ = null in let final dynamic #t45 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:129:48: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
         /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ \"hello\",
-                                               ^" in let final core::String #t46 = "hello" in null, let<BottomType> _ = null in let final dynamic #t47 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:130:48: Error: A value of type 'dart.core::int' can't be assigned to a variable of type 'dart.core::String'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::String'.
+                                               ^" in let final core::String #t46 = "hello" in null, let<BottomType> _ = null in let final dynamic #t47 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:130:48: Error: The argument type 'dart.core::int' can't be assigned to the parameter type 'dart.core::String'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::String'.
         /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 3);
                                                ^" in let final core::int #t48 = 3 in null);
-    self::A<core::int, core::String> a5 = new self::F::named<core::int, core::String>(3, "hello", let<BottomType> _ = null in let final dynamic #t49 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:134:48: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+    self::A<core::int, core::String> a5 = new self::F::named<core::int, core::String>(3, "hello", let<BottomType> _ = null in let final dynamic #t49 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/downwards_inference_on_instance_creations_infer_downwards.dart:134:48: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
         /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ \"hello\");
                                                ^" in let final core::String #t50 = "hello" in null);
   }
diff --git a/pkg/front_end/testcases/inference/future_union_downwards.dart.strong.expect b/pkg/front_end/testcases/inference/future_union_downwards.dart.strong.expect
index 908b887..732664a 100644
--- a/pkg/front_end/testcases/inference/future_union_downwards.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/future_union_downwards.dart.strong.expect
@@ -22,8 +22,8 @@
     return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withoutType("asStream", const <core::Type>[], const <dynamic>[], core::Map::unmodifiable<core::Symbol, dynamic>(const <core::Symbol, dynamic>{}), false)) as{TypeError} asy::Stream<self::MyFuture::T>;
 }
 static field self::MyFuture<dynamic> f;
-static field asy::Future<core::int> t1 = self::f.{self::MyFuture::then}<core::int>((dynamic _) → asy::Future<core::int> => asy::Future::value<core::int>(let dynamic _ = null in let final dynamic #t1 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/future_union_downwards.dart:21:44: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.async::FutureOr<dart.core::int>'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.async::FutureOr<dart.core::int>'.
+static field asy::Future<core::int> t1 = self::f.{self::MyFuture::then}<core::int>((dynamic _) → asy::Future<core::int> => asy::Future::value<core::int>(let dynamic _ = null in let final dynamic #t1 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/future_union_downwards.dart:21:44: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.async::FutureOr<dart.core::int>'.
+Try changing the type of the parameter, or casting the argument to 'dart.async::FutureOr<dart.core::int>'.
         new /*@typeArgs=int*/ Future.value('hi'));
                                            ^" in let final dynamic #t2 = "hi" in null));
 static field asy::Future<core::List<core::int>> t2 = self::f.{self::MyFuture::then}<core::List<core::int>>((dynamic _) → core::List<core::int> => <core::int>[3]);
diff --git a/pkg/front_end/testcases/inference/future_union_downwards.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/future_union_downwards.dart.strong.transformed.expect
index 0e3d51c..f9f9cc1 100644
--- a/pkg/front_end/testcases/inference/future_union_downwards.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/future_union_downwards.dart.strong.transformed.expect
@@ -22,8 +22,8 @@
     return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withoutType("asStream", const <core::Type>[], const <dynamic>[], core::Map::unmodifiable<core::Symbol, dynamic>(const <core::Symbol, dynamic>{}), false)) as{TypeError} asy::Stream<self::MyFuture::T>;
 }
 static field self::MyFuture<dynamic> f;
-static field asy::Future<core::int> t1 = self::f.{self::MyFuture::then}<core::int>((dynamic _) → asy::Future<core::int> => asy::Future::value<core::int>(let<BottomType> _ = null in let final dynamic #t1 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/future_union_downwards.dart:21:44: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.async::FutureOr<dart.core::int>'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.async::FutureOr<dart.core::int>'.
+static field asy::Future<core::int> t1 = self::f.{self::MyFuture::then}<core::int>((dynamic _) → asy::Future<core::int> => asy::Future::value<core::int>(let<BottomType> _ = null in let final dynamic #t1 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/future_union_downwards.dart:21:44: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.async::FutureOr<dart.core::int>'.
+Try changing the type of the parameter, or casting the argument to 'dart.async::FutureOr<dart.core::int>'.
         new /*@typeArgs=int*/ Future.value('hi'));
                                            ^" in let final core::String #t2 = "hi" in null));
 static field asy::Future<core::List<core::int>> t2 = self::f.{self::MyFuture::then}<core::List<core::int>>((dynamic _) → core::List<core::int> => <core::int>[3]);
diff --git a/pkg/front_end/testcases/inference/future_union_downwards_3.dart.strong.expect b/pkg/front_end/testcases/inference/future_union_downwards_3.dart.strong.expect
index 4c8b6d0..86a7783 100644
--- a/pkg/front_end/testcases/inference/future_union_downwards_3.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/future_union_downwards_3.dart.strong.expect
@@ -22,8 +22,8 @@
     return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withoutType("asStream", const <core::Type>[], const <dynamic>[], core::Map::unmodifiable<core::Symbol, dynamic>(const <core::Symbol, dynamic>{}), false)) as{TypeError} asy::Stream<self::MyFuture::T>;
 }
 static field asy::Future<dynamic> f;
-static field asy::Future<core::int> t1 = self::f.{asy::Future::then}<core::int>((dynamic _) → asy::Future<core::int> => asy::Future::value<core::int>(let dynamic _ = null in let final dynamic #t1 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/future_union_downwards_3.dart:21:44: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.async::FutureOr<dart.core::int>'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.async::FutureOr<dart.core::int>'.
+static field asy::Future<core::int> t1 = self::f.{asy::Future::then}<core::int>((dynamic _) → asy::Future<core::int> => asy::Future::value<core::int>(let dynamic _ = null in let final dynamic #t1 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/future_union_downwards_3.dart:21:44: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.async::FutureOr<dart.core::int>'.
+Try changing the type of the parameter, or casting the argument to 'dart.async::FutureOr<dart.core::int>'.
         new /*@typeArgs=int*/ Future.value('hi'));
                                            ^" in let final dynamic #t2 = "hi" in null));
 static field asy::Future<core::List<core::int>> t2 = self::f.{asy::Future::then}<core::List<core::int>>((dynamic _) → core::List<core::int> => <core::int>[3]);
diff --git a/pkg/front_end/testcases/inference/future_union_downwards_3.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/future_union_downwards_3.dart.strong.transformed.expect
index 6e2fe1d..7ee244a 100644
--- a/pkg/front_end/testcases/inference/future_union_downwards_3.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/future_union_downwards_3.dart.strong.transformed.expect
@@ -22,8 +22,8 @@
     return this.{self::MyFuture::noSuchMethod}(new core::_InvocationMirror::_withoutType("asStream", const <core::Type>[], const <dynamic>[], core::Map::unmodifiable<core::Symbol, dynamic>(const <core::Symbol, dynamic>{}), false)) as{TypeError} asy::Stream<self::MyFuture::T>;
 }
 static field asy::Future<dynamic> f;
-static field asy::Future<core::int> t1 = self::f.{asy::Future::then}<core::int>((dynamic _) → asy::Future<core::int> => asy::Future::value<core::int>(let<BottomType> _ = null in let final dynamic #t1 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/future_union_downwards_3.dart:21:44: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.async::FutureOr<dart.core::int>'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.async::FutureOr<dart.core::int>'.
+static field asy::Future<core::int> t1 = self::f.{asy::Future::then}<core::int>((dynamic _) → asy::Future<core::int> => asy::Future::value<core::int>(let<BottomType> _ = null in let final dynamic #t1 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/future_union_downwards_3.dart:21:44: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.async::FutureOr<dart.core::int>'.
+Try changing the type of the parameter, or casting the argument to 'dart.async::FutureOr<dart.core::int>'.
         new /*@typeArgs=int*/ Future.value('hi'));
                                            ^" in let final core::String #t2 = "hi" in null));
 static field asy::Future<core::List<core::int>> t2 = self::f.{asy::Future::then}<core::List<core::int>>((dynamic _) → core::List<core::int> => <core::int>[3]);
diff --git a/pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart.strong.expect b/pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart.strong.expect
index 6662a3f..b5c11d3 100644
--- a/pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart.strong.expect
@@ -16,27 +16,27 @@
   self::printDouble(math::min<core::double>(1.0, 2.0));
   self::printInt(self::myMax(1, 2) as{TypeError} core::int);
   self::printInt(self::myMax(1, 2) as core::int);
-  self::printInt(math::max<core::int>(1, let dynamic _ = null in let final dynamic #t1 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart:29:71: Error: A value of type 'dart.core::double' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+  self::printInt(math::max<core::int>(1, let dynamic _ = null in let final dynamic #t1 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart:29:71: Error: The argument type 'dart.core::double' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
       /*@typeArgs=int*/ max(1, /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 2.0));
                                                                       ^" in let final dynamic #t2 = 2.0 in null));
-  self::printInt(math::min<core::int>(1, let dynamic _ = null in let final dynamic #t3 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart:31:71: Error: A value of type 'dart.core::double' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+  self::printInt(math::min<core::int>(1, let dynamic _ = null in let final dynamic #t3 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart:31:71: Error: The argument type 'dart.core::double' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
       /*@typeArgs=int*/ min(1, /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 2.0));
                                                                       ^" in let final dynamic #t4 = 2.0 in null));
-  self::printDouble(math::max<core::double>(let dynamic _ = null in let final dynamic #t5 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart:33:71: Error: A value of type 'dart.core::int' can't be assigned to a variable of type 'dart.core::double'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::double'.
+  self::printDouble(math::max<core::double>(let dynamic _ = null in let final dynamic #t5 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart:33:71: Error: The argument type 'dart.core::int' can't be assigned to the parameter type 'dart.core::double'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::double'.
       /*@typeArgs=double*/ max(/*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 1, 2.0));
                                                                       ^" in let final dynamic #t6 = 1 in null, 2.0));
-  self::printDouble(math::min<core::double>(let dynamic _ = null in let final dynamic #t7 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart:35:71: Error: A value of type 'dart.core::int' can't be assigned to a variable of type 'dart.core::double'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::double'.
+  self::printDouble(math::min<core::double>(let dynamic _ = null in let final dynamic #t7 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart:35:71: Error: The argument type 'dart.core::int' can't be assigned to the parameter type 'dart.core::double'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::double'.
       /*@typeArgs=double*/ min(/*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 1, 2.0));
                                                                       ^" in let final dynamic #t8 = 1 in null, 2.0));
-  self::printInt(math::min<core::int>(let dynamic _ = null in let final dynamic #t9 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart:39:46: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+  self::printInt(math::min<core::int>(let dynamic _ = null in let final dynamic #t9 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart:39:46: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
       /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ \"hi\",
-                                             ^" in let final dynamic #t10 = "hi" in null, let dynamic _ = null in let final dynamic #t11 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart:40:46: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+                                             ^" in let final dynamic #t10 = "hi" in null, let dynamic _ = null in let final dynamic #t11 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart:40:46: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
       /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ \"there\"));
                                              ^" in let final dynamic #t12 = "there" in null));
 }
diff --git a/pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart.strong.transformed.expect
index 7f186ae..a006e9e 100644
--- a/pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart.strong.transformed.expect
@@ -16,27 +16,27 @@
   self::printDouble(math::min<core::double>(1.0, 2.0));
   self::printInt(self::myMax(1, 2) as{TypeError} core::int);
   self::printInt(self::myMax(1, 2) as core::int);
-  self::printInt(math::max<core::int>(1, let<BottomType> _ = null in let final dynamic #t1 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart:29:71: Error: A value of type 'dart.core::double' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+  self::printInt(math::max<core::int>(1, let<BottomType> _ = null in let final dynamic #t1 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart:29:71: Error: The argument type 'dart.core::double' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
       /*@typeArgs=int*/ max(1, /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 2.0));
                                                                       ^" in let final core::double #t2 = 2.0 in null));
-  self::printInt(math::min<core::int>(1, let<BottomType> _ = null in let final dynamic #t3 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart:31:71: Error: A value of type 'dart.core::double' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+  self::printInt(math::min<core::int>(1, let<BottomType> _ = null in let final dynamic #t3 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart:31:71: Error: The argument type 'dart.core::double' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
       /*@typeArgs=int*/ min(1, /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 2.0));
                                                                       ^" in let final core::double #t4 = 2.0 in null));
-  self::printDouble(math::max<core::double>(let<BottomType> _ = null in let final dynamic #t5 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart:33:71: Error: A value of type 'dart.core::int' can't be assigned to a variable of type 'dart.core::double'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::double'.
+  self::printDouble(math::max<core::double>(let<BottomType> _ = null in let final dynamic #t5 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart:33:71: Error: The argument type 'dart.core::int' can't be assigned to the parameter type 'dart.core::double'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::double'.
       /*@typeArgs=double*/ max(/*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 1, 2.0));
                                                                       ^" in let final core::int #t6 = 1 in null, 2.0));
-  self::printDouble(math::min<core::double>(let<BottomType> _ = null in let final dynamic #t7 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart:35:71: Error: A value of type 'dart.core::int' can't be assigned to a variable of type 'dart.core::double'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::double'.
+  self::printDouble(math::min<core::double>(let<BottomType> _ = null in let final dynamic #t7 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart:35:71: Error: The argument type 'dart.core::int' can't be assigned to the parameter type 'dart.core::double'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::double'.
       /*@typeArgs=double*/ min(/*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 1, 2.0));
                                                                       ^" in let final core::int #t8 = 1 in null, 2.0));
-  self::printInt(math::min<core::int>(let<BottomType> _ = null in let final dynamic #t9 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart:39:46: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+  self::printInt(math::min<core::int>(let<BottomType> _ = null in let final dynamic #t9 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart:39:46: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
       /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ \"hi\",
-                                             ^" in let final core::String #t10 = "hi" in null, let<BottomType> _ = null in let final dynamic #t11 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart:40:46: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+                                             ^" in let final core::String #t10 = "hi" in null, let<BottomType> _ = null in let final dynamic #t11 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_dart_math_min_max.dart:40:46: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
       /*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ \"there\"));
                                              ^" in let final core::String #t12 = "there" in null));
 }
diff --git a/pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart.strong.expect b/pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart.strong.expect
index f260b29..4c1af02 100644
--- a/pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart.strong.expect
@@ -21,12 +21,12 @@
   self::takeIIO(math::max<core::int>);
   self::takeDDO(math::max<core::double>);
   self::takeOOI((math::max<core::Object>) as{TypeError} (core::Object, core::Object) → core::int);
-  self::takeIDI(let dynamic _ = null in let final dynamic #t1 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart:28:73: Error: A value of type '(dart.core::num, dart.core::num) \u8594 dart.core::num' can't be assigned to a variable of type '(dart.core::double, dart.core::int) \u8594 dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to '(dart.core::double, dart.core::int) \u8594 dart.core::int'.
+  self::takeIDI(let dynamic _ = null in let final dynamic #t1 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart:28:73: Error: The argument type '(dart.core::num, dart.core::num) \u8594 dart.core::num' can't be assigned to the parameter type '(dart.core::double, dart.core::int) \u8594 dart.core::int'.
+Try changing the type of the parameter, or casting the argument to '(dart.core::double, dart.core::int) \u8594 dart.core::int'.
       /*error:COULD_NOT_INFER,error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ math.max);
                                                                         ^" in let final dynamic #t2 = math::max<core::num> in null);
-  self::takeDID(let dynamic _ = null in let final dynamic #t3 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart:30:73: Error: A value of type '(dart.core::num, dart.core::num) \u8594 dart.core::num' can't be assigned to a variable of type '(dart.core::int, dart.core::double) \u8594 dart.core::double'.
-Try changing the type of the left hand side, or casting the right hand side to '(dart.core::int, dart.core::double) \u8594 dart.core::double'.
+  self::takeDID(let dynamic _ = null in let final dynamic #t3 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart:30:73: Error: The argument type '(dart.core::num, dart.core::num) \u8594 dart.core::num' can't be assigned to the parameter type '(dart.core::int, dart.core::double) \u8594 dart.core::double'.
+Try changing the type of the parameter, or casting the argument to '(dart.core::int, dart.core::double) \u8594 dart.core::double'.
       /*error:COULD_NOT_INFER,error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ math.max);
                                                                         ^" in let final dynamic #t4 = math::max<core::num> in null);
   self::takeOON((math::max<core::Object>) as{TypeError} (core::Object, core::Object) → core::num);
@@ -41,12 +41,12 @@
   self::takeIIO(math::min<core::int>);
   self::takeDDO(math::min<core::double>);
   self::takeOOI((math::min<core::Object>) as{TypeError} (core::Object, core::Object) → core::int);
-  self::takeIDI(let dynamic _ = null in let final dynamic #t5 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart:46:72: Error: A value of type '(dart.core::num, dart.core::num) \u8594 dart.core::num' can't be assigned to a variable of type '(dart.core::double, dart.core::int) \u8594 dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to '(dart.core::double, dart.core::int) \u8594 dart.core::int'.
+  self::takeIDI(let dynamic _ = null in let final dynamic #t5 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart:46:72: Error: The argument type '(dart.core::num, dart.core::num) \u8594 dart.core::num' can't be assigned to the parameter type '(dart.core::double, dart.core::int) \u8594 dart.core::int'.
+Try changing the type of the parameter, or casting the argument to '(dart.core::double, dart.core::int) \u8594 dart.core::int'.
   takeIDI(/*error:COULD_NOT_INFER,error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ min);
                                                                        ^" in let final dynamic #t6 = math::min<core::num> in null);
-  self::takeDID(let dynamic _ = null in let final dynamic #t7 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart:47:72: Error: A value of type '(dart.core::num, dart.core::num) \u8594 dart.core::num' can't be assigned to a variable of type '(dart.core::int, dart.core::double) \u8594 dart.core::double'.
-Try changing the type of the left hand side, or casting the right hand side to '(dart.core::int, dart.core::double) \u8594 dart.core::double'.
+  self::takeDID(let dynamic _ = null in let final dynamic #t7 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart:47:72: Error: The argument type '(dart.core::num, dart.core::num) \u8594 dart.core::num' can't be assigned to the parameter type '(dart.core::int, dart.core::double) \u8594 dart.core::double'.
+Try changing the type of the parameter, or casting the argument to '(dart.core::int, dart.core::double) \u8594 dart.core::double'.
   takeDID(/*error:COULD_NOT_INFER,error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ min);
                                                                        ^" in let final dynamic #t8 = math::min<core::num> in null);
   self::takeOON((math::min<core::Object>) as{TypeError} (core::Object, core::Object) → core::num);
@@ -63,12 +63,12 @@
   self::takeOON((new self::C::•().{self::C::m}<core::Object>) as{TypeError} (core::Object, core::Object) → core::num);
   self::takeOOO((new self::C::•().{self::C::m}<core::Object>) as{TypeError} (core::Object, core::Object) → core::num);
   self::takeOOI((new self::C::•().{self::C::m}<core::Object>) as{TypeError} (core::Object, core::Object) → core::int);
-  self::takeIDI(let dynamic _ = null in let final dynamic #t9 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart:86:30: Error: A value of type '(dart.core::num, dart.core::num) \u8594 dart.core::num' can't be assigned to a variable of type '(dart.core::double, dart.core::int) \u8594 dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to '(dart.core::double, dart.core::int) \u8594 dart.core::int'.
+  self::takeIDI(let dynamic _ = null in let final dynamic #t9 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart:86:30: Error: The argument type '(dart.core::num, dart.core::num) \u8594 dart.core::num' can't be assigned to the parameter type '(dart.core::double, dart.core::int) \u8594 dart.core::int'.
+Try changing the type of the parameter, or casting the argument to '(dart.core::double, dart.core::int) \u8594 dart.core::int'.
           . /*@target=C::m*/ m);
                              ^" in let final dynamic #t10 = new self::C::•().{self::C::m}<core::num> in null);
-  self::takeDID(let dynamic _ = null in let final dynamic #t11 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart:89:30: Error: A value of type '(dart.core::num, dart.core::num) \u8594 dart.core::num' can't be assigned to a variable of type '(dart.core::int, dart.core::double) \u8594 dart.core::double'.
-Try changing the type of the left hand side, or casting the right hand side to '(dart.core::int, dart.core::double) \u8594 dart.core::double'.
+  self::takeDID(let dynamic _ = null in let final dynamic #t11 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart:89:30: Error: The argument type '(dart.core::num, dart.core::num) \u8594 dart.core::num' can't be assigned to the parameter type '(dart.core::int, dart.core::double) \u8594 dart.core::double'.
+Try changing the type of the parameter, or casting the argument to '(dart.core::int, dart.core::double) \u8594 dart.core::double'.
           . /*@target=C::m*/ m);
                              ^" in let final dynamic #t12 = new self::C::•().{self::C::m}<core::num> in null);
 }
diff --git a/pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart.strong.transformed.expect
index b939213..3d46d45 100644
--- a/pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart.strong.transformed.expect
@@ -21,12 +21,12 @@
   self::takeIIO(math::max<core::int>);
   self::takeDDO(math::max<core::double>);
   self::takeOOI((math::max<core::Object>) as{TypeError} (core::Object, core::Object) → core::int);
-  self::takeIDI(let<BottomType> _ = null in let final dynamic #t1 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart:28:73: Error: A value of type '(dart.core::num, dart.core::num) \u8594 dart.core::num' can't be assigned to a variable of type '(dart.core::double, dart.core::int) \u8594 dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to '(dart.core::double, dart.core::int) \u8594 dart.core::int'.
+  self::takeIDI(let<BottomType> _ = null in let final dynamic #t1 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart:28:73: Error: The argument type '(dart.core::num, dart.core::num) \u8594 dart.core::num' can't be assigned to the parameter type '(dart.core::double, dart.core::int) \u8594 dart.core::int'.
+Try changing the type of the parameter, or casting the argument to '(dart.core::double, dart.core::int) \u8594 dart.core::int'.
       /*error:COULD_NOT_INFER,error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ math.max);
                                                                         ^" in let final (core::num, core::num) → core::num #t2 = math::max<core::num> in null);
-  self::takeDID(let<BottomType> _ = null in let final dynamic #t3 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart:30:73: Error: A value of type '(dart.core::num, dart.core::num) \u8594 dart.core::num' can't be assigned to a variable of type '(dart.core::int, dart.core::double) \u8594 dart.core::double'.
-Try changing the type of the left hand side, or casting the right hand side to '(dart.core::int, dart.core::double) \u8594 dart.core::double'.
+  self::takeDID(let<BottomType> _ = null in let final dynamic #t3 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart:30:73: Error: The argument type '(dart.core::num, dart.core::num) \u8594 dart.core::num' can't be assigned to the parameter type '(dart.core::int, dart.core::double) \u8594 dart.core::double'.
+Try changing the type of the parameter, or casting the argument to '(dart.core::int, dart.core::double) \u8594 dart.core::double'.
       /*error:COULD_NOT_INFER,error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ math.max);
                                                                         ^" in let final (core::num, core::num) → core::num #t4 = math::max<core::num> in null);
   self::takeOON((math::max<core::Object>) as{TypeError} (core::Object, core::Object) → core::num);
@@ -41,12 +41,12 @@
   self::takeIIO(math::min<core::int>);
   self::takeDDO(math::min<core::double>);
   self::takeOOI((math::min<core::Object>) as{TypeError} (core::Object, core::Object) → core::int);
-  self::takeIDI(let<BottomType> _ = null in let final dynamic #t5 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart:46:72: Error: A value of type '(dart.core::num, dart.core::num) \u8594 dart.core::num' can't be assigned to a variable of type '(dart.core::double, dart.core::int) \u8594 dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to '(dart.core::double, dart.core::int) \u8594 dart.core::int'.
+  self::takeIDI(let<BottomType> _ = null in let final dynamic #t5 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart:46:72: Error: The argument type '(dart.core::num, dart.core::num) \u8594 dart.core::num' can't be assigned to the parameter type '(dart.core::double, dart.core::int) \u8594 dart.core::int'.
+Try changing the type of the parameter, or casting the argument to '(dart.core::double, dart.core::int) \u8594 dart.core::int'.
   takeIDI(/*error:COULD_NOT_INFER,error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ min);
                                                                        ^" in let final (core::num, core::num) → core::num #t6 = math::min<core::num> in null);
-  self::takeDID(let<BottomType> _ = null in let final dynamic #t7 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart:47:72: Error: A value of type '(dart.core::num, dart.core::num) \u8594 dart.core::num' can't be assigned to a variable of type '(dart.core::int, dart.core::double) \u8594 dart.core::double'.
-Try changing the type of the left hand side, or casting the right hand side to '(dart.core::int, dart.core::double) \u8594 dart.core::double'.
+  self::takeDID(let<BottomType> _ = null in let final dynamic #t7 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart:47:72: Error: The argument type '(dart.core::num, dart.core::num) \u8594 dart.core::num' can't be assigned to the parameter type '(dart.core::int, dart.core::double) \u8594 dart.core::double'.
+Try changing the type of the parameter, or casting the argument to '(dart.core::int, dart.core::double) \u8594 dart.core::double'.
   takeDID(/*error:COULD_NOT_INFER,error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ min);
                                                                        ^" in let final (core::num, core::num) → core::num #t8 = math::min<core::num> in null);
   self::takeOON((math::min<core::Object>) as{TypeError} (core::Object, core::Object) → core::num);
@@ -63,12 +63,12 @@
   self::takeOON((new self::C::•().{self::C::m}<core::Object>) as{TypeError} (core::Object, core::Object) → core::num);
   self::takeOOO((new self::C::•().{self::C::m}<core::Object>) as{TypeError} (core::Object, core::Object) → core::num);
   self::takeOOI((new self::C::•().{self::C::m}<core::Object>) as{TypeError} (core::Object, core::Object) → core::int);
-  self::takeIDI(let<BottomType> _ = null in let final dynamic #t9 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart:86:30: Error: A value of type '(dart.core::num, dart.core::num) \u8594 dart.core::num' can't be assigned to a variable of type '(dart.core::double, dart.core::int) \u8594 dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to '(dart.core::double, dart.core::int) \u8594 dart.core::int'.
+  self::takeIDI(let<BottomType> _ = null in let final dynamic #t9 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart:86:30: Error: The argument type '(dart.core::num, dart.core::num) \u8594 dart.core::num' can't be assigned to the parameter type '(dart.core::double, dart.core::int) \u8594 dart.core::int'.
+Try changing the type of the parameter, or casting the argument to '(dart.core::double, dart.core::int) \u8594 dart.core::int'.
           . /*@target=C::m*/ m);
                              ^" in let final (core::num, core::num) → core::num #t10 = new self::C::•().{self::C::m}<core::num> in null);
-  self::takeDID(let<BottomType> _ = null in let final dynamic #t11 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart:89:30: Error: A value of type '(dart.core::num, dart.core::num) \u8594 dart.core::num' can't be assigned to a variable of type '(dart.core::int, dart.core::double) \u8594 dart.core::double'.
-Try changing the type of the left hand side, or casting the right hand side to '(dart.core::int, dart.core::double) \u8594 dart.core::double'.
+  self::takeDID(let<BottomType> _ = null in let final dynamic #t11 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_infer_generic_instantiation.dart:89:30: Error: The argument type '(dart.core::num, dart.core::num) \u8594 dart.core::num' can't be assigned to the parameter type '(dart.core::int, dart.core::double) \u8594 dart.core::double'.
+Try changing the type of the parameter, or casting the argument to '(dart.core::int, dart.core::double) \u8594 dart.core::double'.
           . /*@target=C::m*/ m);
                              ^" in let final (core::num, core::num) → core::num #t12 = new self::C::•().{self::C::m}<core::num> in null);
 }
diff --git a/pkg/front_end/testcases/inference/generic_methods_iterable_and_future.dart.strong.expect b/pkg/front_end/testcases/inference/generic_methods_iterable_and_future.dart.strong.expect
index a9ca526..0af21f3 100644
--- a/pkg/front_end/testcases/inference/generic_methods_iterable_and_future.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/generic_methods_iterable_and_future.dart.strong.expect
@@ -12,8 +12,8 @@
 Try correcting the name to the name of an existing method, or defining a method named '+'.
                           /*@type=int*/ y) => /*info:DYNAMIC_CAST,info:DYNAMIC_INVOKE*/ x /*error:UNDEFINED_OPERATOR*/ +
                                                                                                                        ^") as{TypeError} asy::FutureOr<core::String>));
-  asy::Future<core::String> results3 = results.{asy::Future::then}<core::String>((core::List<core::int> list) → asy::FutureOr<core::String> => list.{core::Iterable::fold}<asy::FutureOr<core::String>>("", let dynamic _ = null in let final dynamic #t2 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_iterable_and_future.dart:31:108: Error: A value of type '(dart.core::String, dart.core::int) \u8594 dart.core::String' can't be assigned to a variable of type '(dart.async::FutureOr<dart.core::String>, dart.core::int) \u8594 dart.async::FutureOr<dart.core::String>'.
-Try changing the type of the left hand side, or casting the right hand side to '(dart.async::FutureOr<dart.core::String>, dart.core::int) \u8594 dart.async::FutureOr<dart.core::String>'.
+  asy::Future<core::String> results3 = results.{asy::Future::then}<core::String>((core::List<core::int> list) → asy::FutureOr<core::String> => list.{core::Iterable::fold}<asy::FutureOr<core::String>>("", let dynamic _ = null in let final dynamic #t2 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_iterable_and_future.dart:31:108: Error: The argument type '(dart.core::String, dart.core::int) \u8594 dart.core::String' can't be assigned to the parameter type '(dart.async::FutureOr<dart.core::String>, dart.core::int) \u8594 dart.async::FutureOr<dart.core::String>'.
+Try changing the type of the parameter, or casting the argument to '(dart.async::FutureOr<dart.core::String>, dart.core::int) \u8594 dart.async::FutureOr<dart.core::String>'.
                   /*info:INFERRED_TYPE_CLOSURE,error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ /*@returnType=String*/ (String
                                                                                                            ^" in let final dynamic #t3 = (core::String x, core::int y) → core::String => x.{core::String::+}(y.{core::int::toString}()) in null));
   asy::Future<core::String> results4 = results.{asy::Future::then}<core::String>((core::List<core::int> list) → core::String => list.{core::Iterable::fold}<core::String>("", (core::String x, core::int y) → core::String => x.{core::String::+}(y.{core::int::toString}())));
diff --git a/pkg/front_end/testcases/inference/generic_methods_iterable_and_future.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/generic_methods_iterable_and_future.dart.strong.transformed.expect
index 5577717..221ebfd 100644
--- a/pkg/front_end/testcases/inference/generic_methods_iterable_and_future.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/generic_methods_iterable_and_future.dart.strong.transformed.expect
@@ -12,8 +12,8 @@
 Try correcting the name to the name of an existing method, or defining a method named '+'.
                           /*@type=int*/ y) => /*info:DYNAMIC_CAST,info:DYNAMIC_INVOKE*/ x /*error:UNDEFINED_OPERATOR*/ +
                                                                                                                        ^") as{TypeError} asy::FutureOr<core::String>));
-  asy::Future<core::String> results3 = results.{asy::Future::then}<core::String>((core::List<core::int> list) → asy::FutureOr<core::String> => list.{core::Iterable::fold}<asy::FutureOr<core::String>>("", let<BottomType> _ = null in let final dynamic #t2 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_iterable_and_future.dart:31:108: Error: A value of type '(dart.core::String, dart.core::int) \u8594 dart.core::String' can't be assigned to a variable of type '(dart.async::FutureOr<dart.core::String>, dart.core::int) \u8594 dart.async::FutureOr<dart.core::String>'.
-Try changing the type of the left hand side, or casting the right hand side to '(dart.async::FutureOr<dart.core::String>, dart.core::int) \u8594 dart.async::FutureOr<dart.core::String>'.
+  asy::Future<core::String> results3 = results.{asy::Future::then}<core::String>((core::List<core::int> list) → asy::FutureOr<core::String> => list.{core::Iterable::fold}<asy::FutureOr<core::String>>("", let<BottomType> _ = null in let final dynamic #t2 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/generic_methods_iterable_and_future.dart:31:108: Error: The argument type '(dart.core::String, dart.core::int) \u8594 dart.core::String' can't be assigned to the parameter type '(dart.async::FutureOr<dart.core::String>, dart.core::int) \u8594 dart.async::FutureOr<dart.core::String>'.
+Try changing the type of the parameter, or casting the argument to '(dart.async::FutureOr<dart.core::String>, dart.core::int) \u8594 dart.async::FutureOr<dart.core::String>'.
                   /*info:INFERRED_TYPE_CLOSURE,error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ /*@returnType=String*/ (String
                                                                                                            ^" in let final (core::String, core::int) → core::String #t3 = (core::String x, core::int y) → core::String => x.{core::String::+}(y.{core::int::toString}()) in null));
   asy::Future<core::String> results4 = results.{asy::Future::then}<core::String>((core::List<core::int> list) → core::String => list.{core::Iterable::fold}<core::String>("", (core::String x, core::int y) → core::String => x.{core::String::+}(y.{core::int::toString}())));
diff --git a/pkg/front_end/testcases/inference/list_literals.dart.strong.expect b/pkg/front_end/testcases/inference/list_literals.dart.strong.expect
index 03fddbd..0ef38ce 100644
--- a/pkg/front_end/testcases/inference/list_literals.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/list_literals.dart.strong.expect
@@ -4,12 +4,12 @@
 
 static method test1() → dynamic {
   core::List<core::int> x = <core::int>[1, 2, 3];
-  x.{core::List::add}(let dynamic _ = null in let final dynamic #t1 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/list_literals.dart:10:71: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+  x.{core::List::add}(let dynamic _ = null in let final dynamic #t1 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/list_literals.dart:10:71: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
   x. /*@target=List::add*/ add(/*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 'hi');
                                                                       ^" in let final dynamic #t2 = "hi" in null);
-  x.{core::List::add}(let dynamic _ = null in let final dynamic #t3 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/list_literals.dart:11:71: Error: A value of type 'dart.core::double' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+  x.{core::List::add}(let dynamic _ = null in let final dynamic #t3 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/list_literals.dart:11:71: Error: The argument type 'dart.core::double' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
   x. /*@target=List::add*/ add(/*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 4.0);
                                                                       ^" in let final dynamic #t4 = 4.0 in null);
   x.{core::List::add}(4);
@@ -17,8 +17,8 @@
 }
 static method test2() → dynamic {
   core::List<core::num> x = <core::num>[1, 2.0, 3];
-  x.{core::List::add}(let dynamic _ = null in let final dynamic #t5 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/list_literals.dart:18:71: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::num'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::num'.
+  x.{core::List::add}(let dynamic _ = null in let final dynamic #t5 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/list_literals.dart:18:71: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.core::num'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::num'.
   x. /*@target=List::add*/ add(/*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 'hi');
                                                                       ^" in let final dynamic #t6 = "hi" in null);
   x.{core::List::add}(4.0);
diff --git a/pkg/front_end/testcases/inference/list_literals.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/list_literals.dart.strong.transformed.expect
index 1b7e2aa..c91995d 100644
--- a/pkg/front_end/testcases/inference/list_literals.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/list_literals.dart.strong.transformed.expect
@@ -4,12 +4,12 @@
 
 static method test1() → dynamic {
   core::List<core::int> x = <core::int>[1, 2, 3];
-  x.{core::List::add}(let<BottomType> _ = null in let final dynamic #t1 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/list_literals.dart:10:71: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+  x.{core::List::add}(let<BottomType> _ = null in let final dynamic #t1 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/list_literals.dart:10:71: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
   x. /*@target=List::add*/ add(/*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 'hi');
                                                                       ^" in let final core::String #t2 = "hi" in null);
-  x.{core::List::add}(let<BottomType> _ = null in let final dynamic #t3 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/list_literals.dart:11:71: Error: A value of type 'dart.core::double' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+  x.{core::List::add}(let<BottomType> _ = null in let final dynamic #t3 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/list_literals.dart:11:71: Error: The argument type 'dart.core::double' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
   x. /*@target=List::add*/ add(/*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 4.0);
                                                                       ^" in let final core::double #t4 = 4.0 in null);
   x.{core::List::add}(4);
@@ -17,8 +17,8 @@
 }
 static method test2() → dynamic {
   core::List<core::num> x = <core::num>[1, 2.0, 3];
-  x.{core::List::add}(let<BottomType> _ = null in let final dynamic #t5 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/list_literals.dart:18:71: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::num'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::num'.
+  x.{core::List::add}(let<BottomType> _ = null in let final dynamic #t5 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/list_literals.dart:18:71: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.core::num'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::num'.
   x. /*@target=List::add*/ add(/*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 'hi');
                                                                       ^" in let final core::String #t6 = "hi" in null);
   x.{core::List::add}(4.0);
diff --git a/pkg/front_end/testcases/inference/list_literals_top_level.dart.strong.expect b/pkg/front_end/testcases/inference/list_literals_top_level.dart.strong.expect
index fdc6bfa..f2f1e31 100644
--- a/pkg/front_end/testcases/inference/list_literals_top_level.dart.strong.expect
+++ b/pkg/front_end/testcases/inference/list_literals_top_level.dart.strong.expect
@@ -5,20 +5,20 @@
 static field core::List<core::int> x1 = <core::int>[1, 2, 3];
 static field core::List<core::num> x2 = <core::num>[1, 2.0, 3];
 static method test1() → dynamic {
-  self::x1.{core::List::add}(let dynamic _ = null in let final dynamic #t1 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/list_literals_top_level.dart:10:72: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+  self::x1.{core::List::add}(let dynamic _ = null in let final dynamic #t1 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/list_literals_top_level.dart:10:72: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
   x1. /*@target=List::add*/ add(/*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 'hi');
                                                                        ^" in let final dynamic #t2 = "hi" in null);
-  self::x1.{core::List::add}(let dynamic _ = null in let final dynamic #t3 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/list_literals_top_level.dart:11:72: Error: A value of type 'dart.core::double' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+  self::x1.{core::List::add}(let dynamic _ = null in let final dynamic #t3 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/list_literals_top_level.dart:11:72: Error: The argument type 'dart.core::double' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
   x1. /*@target=List::add*/ add(/*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 4.0);
                                                                        ^" in let final dynamic #t4 = 4.0 in null);
   self::x1.{core::List::add}(4);
   core::List<core::num> y = self::x1;
 }
 static method test2() → dynamic {
-  self::x2.{core::List::add}(let dynamic _ = null in let final dynamic #t5 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/list_literals_top_level.dart:18:72: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::num'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::num'.
+  self::x2.{core::List::add}(let dynamic _ = null in let final dynamic #t5 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/inference/list_literals_top_level.dart:18:72: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.core::num'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::num'.
   x2. /*@target=List::add*/ add(/*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 'hi');
                                                                        ^" in let final dynamic #t6 = "hi" in null);
   self::x2.{core::List::add}(4.0);
diff --git a/pkg/front_end/testcases/inference/list_literals_top_level.dart.strong.transformed.expect b/pkg/front_end/testcases/inference/list_literals_top_level.dart.strong.transformed.expect
index 3788b95..b26fec1 100644
--- a/pkg/front_end/testcases/inference/list_literals_top_level.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/inference/list_literals_top_level.dart.strong.transformed.expect
@@ -5,20 +5,20 @@
 static field core::List<core::int> x1 = <core::int>[1, 2, 3];
 static field core::List<core::num> x2 = <core::num>[1, 2.0, 3];
 static method test1() → dynamic {
-  self::x1.{core::List::add}(let<BottomType> _ = null in let final dynamic #t1 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/list_literals_top_level.dart:10:72: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+  self::x1.{core::List::add}(let<BottomType> _ = null in let final dynamic #t1 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/list_literals_top_level.dart:10:72: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
   x1. /*@target=List::add*/ add(/*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 'hi');
                                                                        ^" in let final core::String #t2 = "hi" in null);
-  self::x1.{core::List::add}(let<BottomType> _ = null in let final dynamic #t3 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/list_literals_top_level.dart:11:72: Error: A value of type 'dart.core::double' can't be assigned to a variable of type 'dart.core::int'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::int'.
+  self::x1.{core::List::add}(let<BottomType> _ = null in let final dynamic #t3 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/list_literals_top_level.dart:11:72: Error: The argument type 'dart.core::double' can't be assigned to the parameter type 'dart.core::int'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::int'.
   x1. /*@target=List::add*/ add(/*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 4.0);
                                                                        ^" in let final core::double #t4 = 4.0 in null);
   self::x1.{core::List::add}(4);
   core::List<core::num> y = self::x1;
 }
 static method test2() → dynamic {
-  self::x2.{core::List::add}(let<BottomType> _ = null in let final dynamic #t5 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/list_literals_top_level.dart:18:72: Error: A value of type 'dart.core::String' can't be assigned to a variable of type 'dart.core::num'.
-Try changing the type of the left hand side, or casting the right hand side to 'dart.core::num'.
+  self::x2.{core::List::add}(let<BottomType> _ = null in let final dynamic #t5 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/inference/list_literals_top_level.dart:18:72: Error: The argument type 'dart.core::String' can't be assigned to the parameter type 'dart.core::num'.
+Try changing the type of the parameter, or casting the argument to 'dart.core::num'.
   x2. /*@target=List::add*/ add(/*error:ARGUMENT_TYPE_NOT_ASSIGNABLE*/ 'hi');
                                                                        ^" in let final core::String #t6 = "hi" in null);
   self::x2.{core::List::add}(4.0);
diff --git a/pkg/front_end/testcases/redirecting_initializer_arguments_test.dart.strong.expect b/pkg/front_end/testcases/redirecting_initializer_arguments_test.dart.strong.expect
index eb883bc..6ec2d0c 100644
--- a/pkg/front_end/testcases/redirecting_initializer_arguments_test.dart.strong.expect
+++ b/pkg/front_end/testcases/redirecting_initializer_arguments_test.dart.strong.expect
@@ -5,8 +5,8 @@
 class Foo<T extends core::Object = dynamic> extends core::Object {
   generic-covariant-impl field self::Foo::T x;
   constructor from(core::String _init) → void
-    : this self::Foo::_internal(x: let dynamic _ = null in let final dynamic #t1 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/redirecting_initializer_arguments_test.dart:12:46: Error: A value of type 'dart.core::String' can't be assigned to a variable of type '#lib1::Foo::T'.
-Try changing the type of the left hand side, or casting the right hand side to '#lib1::Foo::T'.
+    : this self::Foo::_internal(x: let dynamic _ = null in let final dynamic #t1 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/redirecting_initializer_arguments_test.dart:12:46: Error: The argument type 'dart.core::String' can't be assigned to the parameter type '#lib1::Foo::T'.
+Try changing the type of the parameter, or casting the argument to '#lib1::Foo::T'.
   Foo.from(String _init) : this._internal(x: _init);
                                              ^" in let final dynamic #t2 = _init in null)
     ;
diff --git a/pkg/front_end/testcases/redirecting_initializer_arguments_test.dart.strong.transformed.expect b/pkg/front_end/testcases/redirecting_initializer_arguments_test.dart.strong.transformed.expect
index eb883bc..6ec2d0c 100644
--- a/pkg/front_end/testcases/redirecting_initializer_arguments_test.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/redirecting_initializer_arguments_test.dart.strong.transformed.expect
@@ -5,8 +5,8 @@
 class Foo<T extends core::Object = dynamic> extends core::Object {
   generic-covariant-impl field self::Foo::T x;
   constructor from(core::String _init) → void
-    : this self::Foo::_internal(x: let dynamic _ = null in let final dynamic #t1 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/redirecting_initializer_arguments_test.dart:12:46: Error: A value of type 'dart.core::String' can't be assigned to a variable of type '#lib1::Foo::T'.
-Try changing the type of the left hand side, or casting the right hand side to '#lib1::Foo::T'.
+    : this self::Foo::_internal(x: let dynamic _ = null in let final dynamic #t1 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/redirecting_initializer_arguments_test.dart:12:46: Error: The argument type 'dart.core::String' can't be assigned to the parameter type '#lib1::Foo::T'.
+Try changing the type of the parameter, or casting the argument to '#lib1::Foo::T'.
   Foo.from(String _init) : this._internal(x: _init);
                                              ^" in let final dynamic #t2 = _init in null)
     ;
diff --git a/pkg/front_end/testcases/runtime_checks/covariant_generic_method_type_parameter.dart.strong.expect b/pkg/front_end/testcases/runtime_checks/covariant_generic_method_type_parameter.dart.strong.expect
index 3300422..5f06fd8 100644
--- a/pkg/front_end/testcases/runtime_checks/covariant_generic_method_type_parameter.dart.strong.expect
+++ b/pkg/front_end/testcases/runtime_checks/covariant_generic_method_type_parameter.dart.strong.expect
@@ -8,8 +8,8 @@
     ;
   method f<generic-covariant-impl U extends self::C::T = self::C::T>(self::C::f::U x) → void {}
   method g1<generic-covariant-impl U extends self::C::T = self::C::T>() → void {
-    this.{self::C::f}<self::C::g1::U>(let dynamic _ = null in let final dynamic #t1 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/runtime_checks/covariant_generic_method_type_parameter.dart:11:15: Error: A value of type 'dart.core::double' can't be assigned to a variable of type 'test::C::g1::U'.
-Try changing the type of the left hand side, or casting the right hand side to 'test::C::g1::U'.
+    this.{self::C::f}<self::C::g1::U>(let dynamic _ = null in let final dynamic #t1 = let dynamic _ = null in invalid-expression "pkg/front_end/testcases/runtime_checks/covariant_generic_method_type_parameter.dart:11:15: Error: The argument type 'dart.core::double' can't be assigned to the parameter type 'test::C::g1::U'.
+Try changing the type of the parameter, or casting the argument to 'test::C::g1::U'.
     this.f<U>(1.5);
               ^" in let final dynamic #t2 = 1.5 in null);
   }
diff --git a/pkg/front_end/testcases/runtime_checks/covariant_generic_method_type_parameter.dart.strong.transformed.expect b/pkg/front_end/testcases/runtime_checks/covariant_generic_method_type_parameter.dart.strong.transformed.expect
index 1de3ac1..57f48fc 100644
--- a/pkg/front_end/testcases/runtime_checks/covariant_generic_method_type_parameter.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/runtime_checks/covariant_generic_method_type_parameter.dart.strong.transformed.expect
@@ -8,8 +8,8 @@
     ;
   method f<generic-covariant-impl U extends self::C::T = self::C::T>(self::C::f::U x) → void {}
   method g1<generic-covariant-impl U extends self::C::T = self::C::T>() → void {
-    this.{self::C::f}<self::C::g1::U>(let<BottomType> _ = null in let final dynamic #t1 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/runtime_checks/covariant_generic_method_type_parameter.dart:11:15: Error: A value of type 'dart.core::double' can't be assigned to a variable of type 'test::C::g1::U'.
-Try changing the type of the left hand side, or casting the right hand side to 'test::C::g1::U'.
+    this.{self::C::f}<self::C::g1::U>(let<BottomType> _ = null in let final dynamic #t1 = let<BottomType> _ = null in invalid-expression "pkg/front_end/testcases/runtime_checks/covariant_generic_method_type_parameter.dart:11:15: Error: The argument type 'dart.core::double' can't be assigned to the parameter type 'test::C::g1::U'.
+Try changing the type of the parameter, or casting the argument to 'test::C::g1::U'.
     this.f<U>(1.5);
               ^" in let final core::double #t2 = 1.5 in null);
   }