Version 2.12.0-29.0.dev

Merge commit 'f8e03b3cfd1179e39a612650d50fe0c87e6f8f0f' into 'dev'
diff --git a/CHANGELOG.md b/CHANGELOG.md
index e478d0b..c1ed2a0 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -56,8 +56,10 @@
 
 #### Linter
 
-Updated the Linter to `0.1.123`, which includes:
+Updated the Linter to `0.1.124`, which includes:
 
+* Fixed false positives in `prefer_constructors_over_static_methods`.
+* Updates to `package_names` to allow leading underscores.
 * Fixed NPEs in `unnecessary_null_checks`.
 * A fixed NPE in `missing_whitespace_between_adjacent_strings`.
 * Updates to `void_checks` for NNBD.
diff --git a/DEPS b/DEPS
index 1e6598a..51d9353 100644
--- a/DEPS
+++ b/DEPS
@@ -81,7 +81,7 @@
   "cli_util_rev" : "335ed165887d0ec97c2a09173ebf22dcf56a6c4e",
   "clock_rev" : "a494269254ba978e7ef8f192c5f7fec3fc05b9d3",
   "collection_rev": "e4bb038ce2d8e66fb15818aa40685c68d53692ab",
-  "convert_rev": "c1b01f832835d3d8a06b0b246a361c0eaab35d3c",
+  "convert_rev": "dd3bd28f63be7cb8ab961f38bc73229e4473b555",
   "crypto_rev": "f7c48b334b1386bc5ab0f706fbcd6df8496a87fc",
   "csslib_rev": "6f77b3dcee957d3e2d5083f666221a220e9ed1f1",
   "dart2js_info_rev" : "0632a623b08e1f601c7eba99e0186a581ae799e9",
@@ -117,7 +117,7 @@
   "intl_tag": "0.17.0-nullsafety",
   "jinja2_rev": "2222b31554f03e62600cd7e383376a7c187967a1",
   "json_rpc_2_rev": "8f189db8f0c299187a0e8fa959dba7e9b0254be5",
-  "linter_tag": "0.1.123",
+  "linter_tag": "0.1.124",
   "logging_rev": "9d2a7fdd05b09bc06474881152b5baaf38fd1329",
   "markupsafe_rev": "8f45f5cfa0009d2a70589bcda0349b8cb2b72783",
   "markdown_rev": "6f89681d59541ddb1cf3a58efbdaa2304ffc3f51",
@@ -132,7 +132,7 @@
   "ply_rev": "604b32590ffad5cbb82e4afef1d305512d06ae93",
   "pool_rev": "eedbd5fde84f9a1a8da643b475305a81841da599",
   "protobuf_rev": "3746c8fd3f2b0147623a8e3db89c3ff4330de760",
-  "pub_rev": "4ca4767a6c00b2dadecdaee9a4866dae40ef25f2",
+  "pub_rev": "b10966c6a8ad7d95c2023b7842fa2697001d2fdf",
   "pub_semver_tag": "v1.4.4",
   "resource_rev": "6b79867d0becf5395e5819a75720963b8298e9a7",
   "root_certificates_rev": "7e5ec82c99677a2e5b95ce296c4d68b0d3378ed8",
@@ -147,7 +147,7 @@
   "source_maps_rev": "53eb92ccfe6e64924054f83038a534b959b12b3e",
   "source_span_rev": "49ff31eabebed0da0ae6634124f8ba5c6fbf57f1",
   "sse_tag": "e5cf68975e8e87171a3dc297577aa073454a91dc",
-  "stack_trace_tag": "c9c867fa9d5b9c8a059e33d3efe759698aa49d60",
+  "stack_trace_tag": "6788afc61875079b71b3d1c3e65aeaa6a25cbc2f",
   "stagehand_tag": "v3.3.9",
   "stream_channel_tag": "d7251e61253ec389ee6e045ee1042311bced8f1d",
   "string_scanner_rev": "1b63e6e5db5933d7be0a45da6e1129fe00262734",
diff --git a/pkg/analysis_server/lib/src/server/driver.dart b/pkg/analysis_server/lib/src/server/driver.dart
index 18b8438..8e7af39 100644
--- a/pkg/analysis_server/lib/src/server/driver.dart
+++ b/pkg/analysis_server/lib/src/server/driver.dart
@@ -25,8 +25,6 @@
 import 'package:analysis_server/src/server/sdk_configuration.dart';
 import 'package:analysis_server/src/server/stdio_server.dart';
 import 'package:analysis_server/src/services/completion/dart/completion_ranking.dart';
-import 'package:analysis_server/src/services/completion/dart/uri_contributor.dart'
-    show UriContributor;
 import 'package:analysis_server/src/socket_server.dart';
 import 'package:analysis_server/src/utilities/request_statistics.dart';
 import 'package:analysis_server/starter.dart';
@@ -219,9 +217,6 @@
   /// The name of the option used to set the version for the client.
   static const String CLIENT_VERSION = 'client-version';
 
-  /// The name of the option used to enable DartPad specific functionality.
-  static const String DARTPAD_OPTION = 'dartpad';
-
   /// The name of the option used to disable exception handling.
   static const String DISABLE_SERVER_EXCEPTION_HANDLING =
       'disable-server-exception-handling';
@@ -234,9 +229,6 @@
   static const String DISABLE_SERVER_FEATURE_SEARCH =
       'disable-server-feature-search';
 
-  /// The name of the option used to enable instrumentation.
-  static const String ENABLE_INSTRUMENTATION_OPTION = 'enable-instrumentation';
-
   /// The name of the option used to set the file read mode.
   static const String FILE_READ_MODE = 'file-read-mode';
 
@@ -419,10 +411,6 @@
       }
     }
 
-    if (results[DARTPAD_OPTION]) {
-      UriContributor.suggestFilePaths = false;
-    }
-
     {
       bool disableCompletion = results[DISABLE_SERVER_FEATURE_COMPLETION];
       bool disableSearch = results[DISABLE_SERVER_FEATURE_SEARCH];
@@ -747,10 +735,6 @@
         valueHelp: 'name', help: 'an identifier used to identify the client');
     parser.addOption(CLIENT_VERSION,
         valueHelp: 'version', help: 'the version of the client');
-    parser.addFlag(DARTPAD_OPTION,
-        help: 'enable DartPad specific functionality',
-        defaultsTo: false,
-        hide: true);
     parser.addFlag(DISABLE_SERVER_EXCEPTION_HANDLING,
         // TODO(jcollins-g): Pipeline option through and apply to all
         // exception-nullifying runZoned() calls.
@@ -762,10 +746,6 @@
         help: 'disable all completion features', defaultsTo: false, hide: true);
     parser.addFlag(DISABLE_SERVER_FEATURE_SEARCH,
         help: 'disable all search features', defaultsTo: false, hide: true);
-    parser.addFlag(ENABLE_INSTRUMENTATION_OPTION,
-        help: 'enable sending instrumentation information to a server',
-        defaultsTo: false,
-        negatable: false);
     parser.addOption(INSTRUMENTATION_LOG_FILE,
         valueHelp: 'file path',
         help: 'write instrumentation data to the given file');
@@ -831,8 +811,17 @@
     //
     // Deprecated options - no longer read from.
     //
-    parser.addFlag('use-fasta-parser', defaultsTo: true, hide: true);
+
+    // Removed 11/8/2020.
+    parser.addFlag('dartpad', hide: true);
+    // Removed 10/30/2020.
+    parser.addMultiOption('enable-experiment', hide: true);
+    // Removed 9/23/2020.
+    parser.addFlag('enable-instrumentation', hide: true);
+    // Removed 11/8/2020.
     parser.addFlag('preview-dart-2', hide: true);
+    // Removed 9/23/2020.
+    parser.addFlag('use-fasta-parser', hide: true);
 
     return parser;
   }
diff --git a/pkg/analysis_server/lib/src/services/completion/dart/uri_contributor.dart b/pkg/analysis_server/lib/src/services/completion/dart/uri_contributor.dart
index b832581..6e53137 100644
--- a/pkg/analysis_server/lib/src/services/completion/dart/uri_contributor.dart
+++ b/pkg/analysis_server/lib/src/services/completion/dart/uri_contributor.dart
@@ -14,13 +14,6 @@
 /// A contributor that produces suggestions based on the content of the file
 /// system to complete within URIs in import, export and part directives.
 class UriContributor extends DartCompletionContributor {
-  /// A flag indicating whether file: and package: URI suggestions should
-  /// be included in the list of completion suggestions.
-  // TODO(danrubel): remove this flag and related functionality
-  // once the UriContributor limits file: and package: URI suggestions
-  // to only those paths within context roots.
-  static bool suggestFilePaths = true;
-
   @override
   Future<void> computeSuggestions(
       DartCompletionRequest request, SuggestionBuilder builder) async {
@@ -93,17 +86,13 @@
       var partialUri = _extractPartialUri(node);
       if (partialUri != null) {
         _addDartSuggestions();
-        if (UriContributor.suggestFilePaths) {
-          _addPackageSuggestions(partialUri);
-          _addFileSuggestions(partialUri);
-        }
+        _addPackageSuggestions(partialUri);
+        _addFileSuggestions(partialUri);
       }
     } else if (parent is PartDirective && parent.uri == node) {
       var partialUri = _extractPartialUri(node);
       if (partialUri != null) {
-        if (UriContributor.suggestFilePaths) {
-          _addFileSuggestions(partialUri);
-        }
+        _addFileSuggestions(partialUri);
       }
     }
   }
diff --git a/pkg/analysis_server/lib/src/services/correction/dart/make_variable_nullable.dart b/pkg/analysis_server/lib/src/services/correction/dart/make_variable_nullable.dart
index 5a4d2ec..acd8708 100644
--- a/pkg/analysis_server/lib/src/services/correction/dart/make_variable_nullable.dart
+++ b/pkg/analysis_server/lib/src/services/correction/dart/make_variable_nullable.dart
@@ -28,47 +28,17 @@
   Future<void> compute(ChangeBuilder builder) async {
     var node = coveredNode;
     var parent = node?.parent;
-    if (unit.featureSet.isEnabled(Feature.non_nullable) &&
-        parent is AssignmentExpression &&
-        parent.rightHandSide == node) {
-      var leftHandSide = parent.leftHandSide;
-      if (leftHandSide is SimpleIdentifier) {
-        var element = leftHandSide.staticElement;
-        if (element is LocalVariableElement) {
-          var oldType = element.type;
-          var newType = (node as Expression).staticType;
-          if (node is NullLiteral) {
-            newType = (oldType as InterfaceTypeImpl)
-                .withNullability(NullabilitySuffix.question);
-          } else if (!typeSystem.isAssignableTo(
-              oldType, typeSystem.promoteToNonNull(newType))) {
-            return;
-          }
-          var declarationList =
-              _findDeclaration(element, parent.thisOrAncestorOfType<Block>());
-          if (declarationList == null || declarationList.variables.length > 1) {
-            return;
-          }
-          var variable = declarationList.variables[0];
-          _variableName = variable.name.name;
-          await builder.addDartFileEdit(file, (builder) {
-            var keyword = declarationList.keyword;
-            if (keyword != null && keyword.type == Keyword.VAR) {
-              builder.addReplacement(range.token(keyword), (builder) {
-                builder.writeType(newType);
-              });
-            } else if (keyword == null) {
-              if (declarationList.type == null) {
-                builder.addInsertion(variable.offset, (builder) {
-                  builder.writeType(newType);
-                  builder.write(' ');
-                });
-              } else {
-                builder.addSimpleInsertion(declarationList.type.end, '?');
-              }
-            }
-          });
-        }
+    if (unit.featureSet.isEnabled(Feature.non_nullable)) {
+      if (node is SimpleIdentifier && parent is SimpleFormalParameter) {
+        await _forSimpleFormalParameter(builder, node, parent);
+      } else if (node is SimpleIdentifier &&
+          parent is FunctionTypedFormalParameter) {
+        await _forFunctionTypedFormalParameter(builder, node, parent);
+      } else if (node is SimpleIdentifier && parent is FieldFormalParameter) {
+        await _forFieldFormalParameter(builder, node, parent);
+      } else if (parent is AssignmentExpression &&
+          parent.rightHandSide == node) {
+        await _forVariableDeclaration(builder, node, parent);
       }
     }
   }
@@ -101,6 +71,108 @@
     return null;
   }
 
+  /// Makes [parameter] nullable if possible.
+  Future<void> _forFieldFormalParameter(ChangeBuilder builder,
+      SimpleIdentifier name, FieldFormalParameter parameter) async {
+    if (parameter.parameters != null) {
+      // A function-typed field formal parameter.
+      if (parameter.question != null) {
+        return;
+      }
+      _variableName = parameter.identifier.name;
+      await builder.addDartFileEdit(file, (builder) {
+        // Add '?' after `)`.
+        builder.addSimpleInsertion(parameter.endToken.end, '?');
+      });
+    } else {
+      if (!_typeCanBeMadeNullable(parameter.type)) {
+        return;
+      }
+      _variableName = parameter.identifier.name;
+      await builder.addDartFileEdit(file, (builder) {
+        builder.addSimpleInsertion(parameter.type.end, '?');
+      });
+    }
+  }
+
+  /// Makes [parameter] nullable if possible.
+  Future<void> _forFunctionTypedFormalParameter(ChangeBuilder builder,
+      SimpleIdentifier name, FunctionTypedFormalParameter parameter) async {
+    if (parameter.question != null) {
+      return;
+    }
+    _variableName = parameter.identifier.name;
+    await builder.addDartFileEdit(file, (builder) {
+      // Add '?' after `)`.
+      builder.addSimpleInsertion(parameter.endToken.end, '?');
+    });
+  }
+
+  Future<void> _forSimpleFormalParameter(ChangeBuilder builder,
+      SimpleIdentifier name, SimpleFormalParameter parameter) async {
+    if (!_typeCanBeMadeNullable(parameter.type)) {
+      return;
+    }
+    _variableName = parameter.identifier.name;
+    await builder.addDartFileEdit(file, (builder) {
+      builder.addSimpleInsertion(parameter.type.end, '?');
+    });
+  }
+
+  Future<void> _forVariableDeclaration(
+      ChangeBuilder builder, AstNode node, AssignmentExpression parent) async {
+    var leftHandSide = parent.leftHandSide;
+    if (leftHandSide is SimpleIdentifier) {
+      var element = leftHandSide.staticElement;
+      if (element is LocalVariableElement) {
+        var oldType = element.type;
+        var newType = (node as Expression).staticType;
+        if (node is NullLiteral) {
+          newType = (oldType as InterfaceTypeImpl)
+              .withNullability(NullabilitySuffix.question);
+        } else if (!typeSystem.isAssignableTo(
+            oldType, typeSystem.promoteToNonNull(newType))) {
+          return;
+        }
+        var declarationList =
+            _findDeclaration(element, parent.thisOrAncestorOfType<Block>());
+        if (declarationList == null || declarationList.variables.length > 1) {
+          return;
+        }
+        var variable = declarationList.variables[0];
+        _variableName = variable.name.name;
+        await builder.addDartFileEdit(file, (builder) {
+          var keyword = declarationList.keyword;
+          if (keyword != null && keyword.type == Keyword.VAR) {
+            builder.addReplacement(range.token(keyword), (builder) {
+              builder.writeType(newType);
+            });
+          } else if (keyword == null) {
+            if (declarationList.type == null) {
+              builder.addInsertion(variable.offset, (builder) {
+                builder.writeType(newType);
+                builder.write(' ');
+              });
+            } else {
+              builder.addSimpleInsertion(declarationList.type.end, '?');
+            }
+          }
+        });
+      }
+    }
+  }
+
+  bool _typeCanBeMadeNullable(TypeAnnotation typeAnnotation) {
+    // Ensure that there is a type annotation.
+    if (typeAnnotation == null) {
+      return false;
+    }
+    if (typeSystem.isNullable(typeAnnotation.type)) {
+      return false;
+    }
+    return true;
+  }
+
   /// Return an instance of this class. Used as a tear-off in `FixProcessor`.
   static MakeVariableNullable newInstance() => MakeVariableNullable();
 }
diff --git a/pkg/analysis_server/lib/src/services/correction/fix_internal.dart b/pkg/analysis_server/lib/src/services/correction/fix_internal.dart
index ef8c359..30ab805 100644
--- a/pkg/analysis_server/lib/src/services/correction/fix_internal.dart
+++ b/pkg/analysis_server/lib/src/services/correction/fix_internal.dart
@@ -727,6 +727,7 @@
     ],
     CompileTimeErrorCode.MISSING_DEFAULT_VALUE_FOR_PARAMETER: [
       AddRequiredKeyword.newInstance,
+      MakeVariableNullable.newInstance,
     ],
     CompileTimeErrorCode.MISSING_REQUIRED_ARGUMENT: [
       AddMissingRequiredArgument.newInstance,
diff --git a/pkg/analysis_server/test/services/completion/dart/uri_contributor_test.dart b/pkg/analysis_server/test/services/completion/dart/uri_contributor_test.dart
index 3d4a399..e19ca34 100644
--- a/pkg/analysis_server/test/services/completion/dart/uri_contributor_test.dart
+++ b/pkg/analysis_server/test/services/completion/dart/uri_contributor_test.dart
@@ -88,30 +88,6 @@
         csKind: CompletionSuggestionKind.IMPORT);
   }
 
-  Future<void> test_export_package2_off() async {
-    try {
-      UriContributor.suggestFilePaths = false;
-
-      var fooRootPath = '$workspaceRootPath/foo';
-      var barRootPath = '$workspaceRootPath/bar';
-      newFile('$fooRootPath/lib/foo.dart', content: 'library foo;');
-      newFile('$fooRootPath/lib/baz/too.dart', content: 'library too;');
-      newFile('$barRootPath/lib/bar.dart', content: 'library bar;');
-
-      writeTestPackageConfig(
-        config: PackageConfigFileBuilder()
-          ..add(name: 'foo', rootPath: fooRootPath)
-          ..add(name: 'bar', rootPath: barRootPath),
-      );
-
-      addTestSource('export "package:foo/baz/^" import');
-      await computeSuggestions();
-      assertNotSuggested('package:foo/baz/too.dart');
-    } finally {
-      UriContributor.suggestFilePaths = true;
-    }
-  }
-
   Future<void> test_import() async {
     addTestSource('import "^"');
     await computeSuggestions();
@@ -199,30 +175,6 @@
     assertNotSuggested('../blat.dart');
   }
 
-  Future<void> test_import_file2_off() async {
-    try {
-      UriContributor.suggestFilePaths = false;
-
-      testFile = convertPath('$testPackageRootPath/test.dart');
-      newFile('$testPackageRootPath/other.dart');
-      newFile('$testPackageRootPath/foo/bar.dart');
-      newFile('$workspaceRootPath/blat.dart');
-
-      addTestSource('import "..^" import');
-      await computeSuggestions();
-      expect(replacementOffset, completionOffset - 2);
-      expect(replacementLength, 2);
-      assertNotSuggested('completion.dart');
-      assertNotSuggested('other.dart');
-      assertNotSuggested('foo');
-      assertNotSuggested('foo/');
-      assertNotSuggested('foo/bar.dart');
-      assertNotSuggested('../blat.dart');
-    } finally {
-      UriContributor.suggestFilePaths = true;
-    }
-  }
-
   Future<void> test_import_file_child() async {
     testFile = convertPath('$testPackageRootPath/test.dart');
     newFile('$testPackageRootPath/other.dart');
@@ -365,30 +317,6 @@
         csKind: CompletionSuggestionKind.IMPORT);
   }
 
-  Future<void> test_import_package2_off() async {
-    try {
-      UriContributor.suggestFilePaths = false;
-
-      var fooRootPath = '$workspaceRootPath/foo';
-      var barRootPath = '$workspaceRootPath/bar';
-      newFile('$fooRootPath/lib/foo.dart');
-      newFile('$fooRootPath/lib/baz/too.dart');
-      newFile('$barRootPath/lib/bar.dart');
-
-      writeTestPackageConfig(
-        config: PackageConfigFileBuilder()
-          ..add(name: 'foo', rootPath: fooRootPath)
-          ..add(name: 'bar', rootPath: barRootPath),
-      );
-
-      addTestSource('import "package:foo/baz/^" import');
-      await computeSuggestions();
-      assertNotSuggested('package:foo/baz/too.dart');
-    } finally {
-      UriContributor.suggestFilePaths = true;
-    }
-  }
-
   Future<void> test_import_package2_raw() async {
     var fooRootPath = '$workspaceRootPath/foo';
     var barRootPath = '$workspaceRootPath/bar';
diff --git a/pkg/analysis_server/test/src/services/correction/fix/make_variable_nullable_test.dart b/pkg/analysis_server/test/src/services/correction/fix/make_variable_nullable_test.dart
index 39575528..804f106 100644
--- a/pkg/analysis_server/test/src/services/correction/fix/make_variable_nullable_test.dart
+++ b/pkg/analysis_server/test/src/services/correction/fix/make_variable_nullable_test.dart
@@ -21,6 +21,57 @@
   @override
   FixKind get kind => DartFixKind.MAKE_VARIABLE_NULLABLE;
 
+  Future<void> test_fieldFormalParameter() async {
+    await resolveTestCode('''
+class C {
+  String? s;
+  C({String this.s});
+}
+''');
+    // TODO(srawlins): Remove the type if the quick fix as is would use the same
+    // type as the field's type.
+    await assertHasFix('''
+class C {
+  String? s;
+  C({String? this.s});
+}
+''');
+  }
+
+  Future<void> test_fieldFormalParameter_functionTyped() async {
+    await resolveTestCode('''
+class C {
+  String Function()? s;
+  C({String this.s()});
+}
+''');
+    await assertHasFix('''
+class C {
+  String Function()? s;
+  C({String this.s()?});
+}
+''');
+  }
+
+  Future<void> test_fieldFormalParameter_untyped() async {
+    await resolveTestCode('''
+class C {
+  String s;
+  C({this.s});
+}
+''');
+    await assertNoFix();
+  }
+
+  Future<void> test_functionTypedFormalParameter() async {
+    await resolveTestCode('''
+void f({String s()}) {}
+''');
+    await assertHasFix('''
+void f({String s()?}) {}
+''');
+  }
+
   Future<void> test_lhsNotIdentifier() async {
     await resolveTestCode('''
 void f(C c) {
@@ -73,6 +124,42 @@
 ''');
   }
 
+  Future<void> test_simpleFormalParameter() async {
+    await resolveTestCode('''
+void f({String s}) {}
+''');
+    await assertHasFix('''
+void f({String? s}) {}
+''');
+  }
+
+  Future<void> test_simpleFormalParameter_final() async {
+    await resolveTestCode('''
+void f({final String s}) {}
+''');
+    await assertHasFix('''
+void f({final String? s}) {}
+''');
+  }
+
+  Future<void> test_simpleFormalParameter_functionType() async {
+    await resolveTestCode('''
+void f({String Function() s}) {}
+''');
+    await assertHasFix('''
+void f({String Function()? s}) {}
+''');
+  }
+
+  Future<void> test_simpleFormalParameter_typeVariable() async {
+    await resolveTestCode('''
+void f<T>({T s}) {}
+''');
+    await assertHasFix('''
+void f<T>({T? s}) {}
+''');
+  }
+
   Future<void> test_type() async {
     await resolveTestCode('''
 void f() {
diff --git a/pkg/analyzer/lib/src/dart/element/element.dart b/pkg/analyzer/lib/src/dart/element/element.dart
index edbdcfa..74cdd53 100644
--- a/pkg/analyzer/lib/src/dart/element/element.dart
+++ b/pkg/analyzer/lib/src/dart/element/element.dart
@@ -7498,7 +7498,7 @@
           typeParameters.typeParameters.map<TypeParameterElement>((node) {
         var reference = containerRef.getChild(node.name.name);
         if (reference.hasElementFor(node)) {
-          return reference.element as TypeParameterElement;
+          return reference.element as TypeParameterElement /*!*/;
         }
         return TypeParameterElementImpl.forLinkedNode(this, reference, node);
       }).toList();
diff --git a/pkg/analyzer/lib/src/dart/scanner/scanner.dart b/pkg/analyzer/lib/src/dart/scanner/scanner.dart
index 56ff5ef..48aab67 100644
--- a/pkg/analyzer/lib/src/dart/scanner/scanner.dart
+++ b/pkg/analyzer/lib/src/dart/scanner/scanner.dart
@@ -51,7 +51,7 @@
 
   final List<int> lineStarts = <int>[];
 
-  Token firstToken;
+  /*late final*/ Token firstToken;
 
   /// A flag indicating whether the scanner should recognize the `>>>` operator
   /// and the `>>>=` operator.
diff --git a/pkg/analyzer/test/error/error_test.dart b/pkg/analyzer/test/error/error_test.dart
index da20e5e..2e48e60 100644
--- a/pkg/analyzer/test/error/error_test.dart
+++ b/pkg/analyzer/test/error/error_test.dart
@@ -58,9 +58,9 @@
     List<String> listedCodes = <String>[];
     CompilationUnit listingUnit = parseFile(['lib', 'error', 'error.dart']);
     TopLevelVariableDeclaration declaration = listingUnit.declarations
+        .whereType<TopLevelVariableDeclaration>()
         .firstWhere(
             (member) =>
-                member is TopLevelVariableDeclaration &&
                 member.variables.variables[0].name.name == 'errorCodeValues',
             orElse: () => null);
     ListLiteral listLiteral = declaration.variables.variables[0].initializer;
diff --git a/pkg/analyzer/test/file_system/memory_file_system_test.dart b/pkg/analyzer/test/file_system/memory_file_system_test.dart
index a1fe32f..c5a929b 100644
--- a/pkg/analyzer/test/file_system/memory_file_system_test.dart
+++ b/pkg/analyzer/test/file_system/memory_file_system_test.dart
@@ -104,8 +104,8 @@
 
 @reflectiveTest
 class MemoryFileSourceExistingTest extends BaseTest {
-  String sourcePath;
-  Source source;
+  /*late*/ String sourcePath;
+  /*late*/ Source source;
 
   @override
   setUp() {
@@ -184,8 +184,8 @@
 
 @reflectiveTest
 class MemoryFileSourceNotExistingTest extends BaseTest {
-  String sourcePath;
-  Source source;
+  /*late*/ String sourcePath;
+  /*late*/ Source source;
 
   @override
   setUp() {
@@ -516,7 +516,7 @@
 
   _watchingFolder(
       String path, Function(List<WatchEvent> changesReceived) test) {
-    Folder folder = provider.getResource(path);
+    var folder = provider.getResource(path) as Folder;
     var changesReceived = <WatchEvent>[];
     folder.changes.listen(changesReceived.add);
     return test(changesReceived);
diff --git a/pkg/analyzer/test/file_system/physical_resource_provider_watch_test.dart b/pkg/analyzer/test/file_system/physical_resource_provider_watch_test.dart
index 71ab2b6..c08137e 100644
--- a/pkg/analyzer/test/file_system/physical_resource_provider_watch_test.dart
+++ b/pkg/analyzer/test/file_system/physical_resource_provider_watch_test.dart
@@ -143,7 +143,8 @@
     // start watching are sometimes misclassified as happening just after
     // we start watching.
     return _delayed(() {
-      File file = PhysicalResourceProvider.INSTANCE.getResource(filePath);
+      var file =
+          PhysicalResourceProvider.INSTANCE.getResource(filePath) as File;
       var changesReceived = <WatchEvent>[];
       var subscription = file.changes.listen(changesReceived.add);
       // Delay running the rest of the test to allow file.changes propagate.
@@ -160,7 +161,8 @@
     // start watching are sometimes misclassified as happening just after
     // we start watching.
     return _delayed(() {
-      Folder folder = PhysicalResourceProvider.INSTANCE.getResource(filePath);
+      var folder =
+          PhysicalResourceProvider.INSTANCE.getResource(filePath) as Folder;
       var changesReceived = <WatchEvent>[];
       var subscription = folder.changes.listen(changesReceived.add);
       // Delay running the rest of the test to allow folder.changes to
diff --git a/pkg/analyzer/test/generated/elements_types_mixin.dart b/pkg/analyzer/test/generated/elements_types_mixin.dart
index 3f8afd5..0476d18 100644
--- a/pkg/analyzer/test/generated/elements_types_mixin.dart
+++ b/pkg/analyzer/test/generated/elements_types_mixin.dart
@@ -91,17 +91,17 @@
 
   InterfaceTypeImpl get nullNone {
     var element = typeProvider.nullType.element;
-    return interfaceTypeNone(element);
+    return interfaceTypeNone(element) as InterfaceTypeImpl;
   }
 
   InterfaceTypeImpl get nullQuestion {
     var element = typeProvider.nullType.element;
-    return interfaceTypeQuestion(element);
+    return interfaceTypeQuestion(element) as InterfaceTypeImpl;
   }
 
   InterfaceTypeImpl get nullStar {
     var element = typeProvider.nullType.element;
-    return interfaceTypeStar(element);
+    return interfaceTypeStar(element) as InterfaceTypeImpl;
   }
 
   InterfaceType get numNone {
@@ -222,7 +222,7 @@
   }) {
     return FunctionTypeAliasElementImpl(name, 0)
       ..typeParameters = typeParameters
-      ..function = function;
+      ..function = function as GenericFunctionTypeElementImpl;
   }
 
   FunctionType functionTypeAliasType(
@@ -279,42 +279,42 @@
     return typeProvider.futureElement.instantiate(
       typeArguments: [type],
       nullabilitySuffix: NullabilitySuffix.none,
-    );
+    ) as InterfaceTypeImpl;
   }
 
   InterfaceTypeImpl futureOrNone(DartType type) {
     return typeProvider.futureOrElement.instantiate(
       typeArguments: [type],
       nullabilitySuffix: NullabilitySuffix.none,
-    );
+    ) as InterfaceTypeImpl;
   }
 
   InterfaceTypeImpl futureOrQuestion(DartType type) {
     return typeProvider.futureOrElement.instantiate(
       typeArguments: [type],
       nullabilitySuffix: NullabilitySuffix.question,
-    );
+    ) as InterfaceTypeImpl;
   }
 
   InterfaceTypeImpl futureOrStar(DartType type) {
     return typeProvider.futureOrElement.instantiate(
       typeArguments: [type],
       nullabilitySuffix: NullabilitySuffix.star,
-    );
+    ) as InterfaceTypeImpl;
   }
 
   InterfaceTypeImpl futureQuestion(DartType type) {
     return typeProvider.futureElement.instantiate(
       typeArguments: [type],
       nullabilitySuffix: NullabilitySuffix.question,
-    );
+    ) as InterfaceTypeImpl;
   }
 
   InterfaceTypeImpl futureStar(DartType type) {
     return typeProvider.futureElement.instantiate(
       typeArguments: [type],
       nullabilitySuffix: NullabilitySuffix.star,
-    );
+    ) as InterfaceTypeImpl;
   }
 
   DartType futureType(DartType T) {
diff --git a/pkg/analyzer/test/generated/parser_fasta_test.dart b/pkg/analyzer/test/generated/parser_fasta_test.dart
index 5a6b51f..d054a17 100644
--- a/pkg/analyzer/test/generated/parser_fasta_test.dart
+++ b/pkg/analyzer/test/generated/parser_fasta_test.dart
@@ -61,11 +61,11 @@
       sdkVersion: '2.0.0', additionalFeatures: [Feature.triple_shift]);
 
   void test_parse_member_called_late() {
-    CompilationUnitImpl unit = parseCompilationUnit(
+    var unit = parseCompilationUnit(
         'class C { void late() { new C().late(); } }',
         featureSet: nonNullable);
-    ClassDeclaration declaration = unit.declarations[0];
-    MethodDeclaration method = declaration.members[0];
+    var declaration = unit.declarations[0] as ClassDeclaration;
+    var method = declaration.members[0] as MethodDeclaration;
 
     expect(method.documentationComment, isNull);
     expect(method.externalKeyword, isNull);
@@ -78,9 +78,9 @@
     expect(method.parameters, isNotNull);
     expect(method.body, isNotNull);
 
-    BlockFunctionBody body = method.body;
-    ExpressionStatement statement = body.block.statements[0];
-    MethodInvocation invocation = statement.expression;
+    var body = method.body as BlockFunctionBody;
+    var statement = body.block.statements[0] as ExpressionStatement;
+    var invocation = statement.expression as MethodInvocation;
     expect(invocation.operator.lexeme, '.');
     expect(invocation.toSource(), 'new C().late()');
   }
@@ -98,11 +98,11 @@
   }
 
   void test_parseClassMember_operator_gtgtgt() {
-    CompilationUnitImpl unit = parseCompilationUnit(
+    var unit = parseCompilationUnit(
         'class C { bool operator >>>(other) => false; }',
         featureSet: tripleShift);
-    ClassDeclaration declaration = unit.declarations[0];
-    MethodDeclaration method = declaration.members[0];
+    var declaration = unit.declarations[0] as ClassDeclaration;
+    var method = declaration.members[0] as MethodDeclaration;
 
     expect(method.documentationComment, isNull);
     expect(method.externalKeyword, isNull);
@@ -117,7 +117,7 @@
   }
 
   void test_parseClassMember_operator_gtgtgteq() {
-    CompilationUnitImpl unit = parseCompilationUnit(
+    var unit = parseCompilationUnit(
         'class C { foo(int value) { x >>>= value; } }',
         featureSet: tripleShift);
     var declaration = unit.declarations[0] as ClassDeclaration;
@@ -506,376 +506,377 @@
   }
 
   void test_listLiteral_for() {
-    ListLiteral list = parseCollectionLiteral(
+    var list = parseCollectionLiteral(
       '[1, await for (var x in list) 2]',
       inAsync: true,
-    );
+    ) as ListLiteral;
     expect(list.elements, hasLength(2));
-    IntegerLiteral first = list.elements[0];
+    var first = list.elements[0] as IntegerLiteral;
     expect(first.value, 1);
 
-    ForElement second = list.elements[1];
+    var second = list.elements[1] as ForElement;
     expect(second.awaitKeyword, isNotNull);
     expect(second.forKeyword.isKeyword, isTrue);
     expect(second.leftParenthesis.lexeme, '(');
     expect(second.rightParenthesis.lexeme, ')');
-    ForEachPartsWithDeclaration forLoopParts = second.forLoopParts;
+    var forLoopParts = second.forLoopParts as ForEachPartsWithDeclaration;
     DeclaredIdentifier forLoopVar = forLoopParts.loopVariable;
     expect(forLoopVar.identifier.name, 'x');
     expect(forLoopParts.inKeyword, isNotNull);
-    SimpleIdentifier iterable = forLoopParts.iterable;
+    var iterable = forLoopParts.iterable as SimpleIdentifier;
     expect(iterable.name, 'list');
   }
 
   void test_listLiteral_forIf() {
-    ListLiteral list = parseCollectionLiteral(
+    var list = parseCollectionLiteral(
       '[1, await for (var x in list) if (c) 2]',
       inAsync: true,
-    );
+    ) as ListLiteral;
     expect(list.elements, hasLength(2));
-    IntegerLiteral first = list.elements[0];
+    var first = list.elements[0] as IntegerLiteral;
     expect(first.value, 1);
 
-    ForElement second = list.elements[1];
+    var second = list.elements[1] as ForElement;
     expect(second.awaitKeyword, isNotNull);
     expect(second.forKeyword.isKeyword, isTrue);
     expect(second.leftParenthesis.lexeme, '(');
     expect(second.rightParenthesis.lexeme, ')');
-    ForEachPartsWithDeclaration forLoopParts = second.forLoopParts;
+    var forLoopParts = second.forLoopParts as ForEachPartsWithDeclaration;
     DeclaredIdentifier forLoopVar = forLoopParts.loopVariable;
     expect(forLoopVar.identifier.name, 'x');
     expect(forLoopParts.inKeyword, isNotNull);
-    SimpleIdentifier iterable = forLoopParts.iterable;
+    var iterable = forLoopParts.iterable as SimpleIdentifier;
     expect(iterable.name, 'list');
 
-    IfElement body = second.body;
-    SimpleIdentifier condition = body.condition;
+    var body = second.body as IfElement;
+    var condition = body.condition as SimpleIdentifier;
     expect(condition.name, 'c');
-    IntegerLiteral thenElement = body.thenElement;
+    var thenElement = body.thenElement as IntegerLiteral;
     expect(thenElement.value, 2);
   }
 
   void test_listLiteral_forSpread() {
-    ListLiteral list =
-        parseCollectionLiteral('[1, for (int x = 0; x < 10; ++x) ...[2]]');
+    var list =
+        parseCollectionLiteral('[1, for (int x = 0; x < 10; ++x) ...[2]]')
+            as ListLiteral;
     expect(list.elements, hasLength(2));
-    IntegerLiteral first = list.elements[0];
+    var first = list.elements[0] as IntegerLiteral;
     expect(first.value, 1);
 
-    ForElement second = list.elements[1];
+    var second = list.elements[1] as ForElement;
     expect(second.awaitKeyword, isNull);
     expect(second.forKeyword.isKeyword, isTrue);
     expect(second.leftParenthesis.lexeme, '(');
     expect(second.rightParenthesis.lexeme, ')');
-    ForPartsWithDeclarations forLoopParts = second.forLoopParts;
+    var forLoopParts = second.forLoopParts as ForPartsWithDeclarations;
     VariableDeclaration forLoopVar = forLoopParts.variables.variables[0];
     expect(forLoopVar.name.name, 'x');
-    BinaryExpression condition = forLoopParts.condition;
-    IntegerLiteral rightOperand = condition.rightOperand;
+    var condition = forLoopParts.condition as BinaryExpression;
+    var rightOperand = condition.rightOperand as IntegerLiteral;
     expect(rightOperand.value, 10);
-    PrefixExpression updater = forLoopParts.updaters[0];
-    SimpleIdentifier updaterOperand = updater.operand;
+    var updater = forLoopParts.updaters[0] as PrefixExpression;
+    var updaterOperand = updater.operand as SimpleIdentifier;
     expect(updaterOperand.name, 'x');
   }
 
   void test_listLiteral_if() {
-    ListLiteral list = parseCollectionLiteral('[1, if (true) 2]');
+    var list = parseCollectionLiteral('[1, if (true) 2]') as ListLiteral;
     expect(list.elements, hasLength(2));
-    IntegerLiteral first = list.elements[0];
+    var first = list.elements[0] as IntegerLiteral;
     expect(first.value, 1);
 
-    IfElement second = list.elements[1];
-    BooleanLiteral condition = second.condition;
+    var second = list.elements[1] as IfElement;
+    var condition = second.condition as BooleanLiteral;
     expect(condition.value, isTrue);
-    IntegerLiteral thenElement = second.thenElement;
+    var thenElement = second.thenElement as IntegerLiteral;
     expect(thenElement.value, 2);
     expect(second.elseElement, isNull);
   }
 
   void test_listLiteral_ifElse() {
-    ListLiteral list = parseCollectionLiteral('[1, if (true) 2 else 5]');
+    var list = parseCollectionLiteral('[1, if (true) 2 else 5]') as ListLiteral;
     expect(list.elements, hasLength(2));
-    IntegerLiteral first = list.elements[0];
+    var first = list.elements[0] as IntegerLiteral;
     expect(first.value, 1);
 
-    IfElement second = list.elements[1];
-    BooleanLiteral condition = second.condition;
+    var second = list.elements[1] as IfElement;
+    var condition = second.condition as BooleanLiteral;
     expect(condition.value, isTrue);
-    IntegerLiteral thenElement = second.thenElement;
+    var thenElement = second.thenElement as IntegerLiteral;
     expect(thenElement.value, 2);
-    IntegerLiteral elseElement = second.elseElement;
+    var elseElement = second.elseElement as IntegerLiteral;
     expect(elseElement.value, 5);
   }
 
   void test_listLiteral_ifElseFor() {
-    ListLiteral list =
-        parseCollectionLiteral('[1, if (true) 2 else for (a in b) 5]');
+    var list = parseCollectionLiteral('[1, if (true) 2 else for (a in b) 5]')
+        as ListLiteral;
     expect(list.elements, hasLength(2));
-    IntegerLiteral first = list.elements[0];
+    var first = list.elements[0] as IntegerLiteral;
     expect(first.value, 1);
 
-    IfElement second = list.elements[1];
-    BooleanLiteral condition = second.condition;
+    var second = list.elements[1] as IfElement;
+    var condition = second.condition as BooleanLiteral;
     expect(condition.value, isTrue);
-    IntegerLiteral thenElement = second.thenElement;
+    var thenElement = second.thenElement as IntegerLiteral;
     expect(thenElement.value, 2);
 
-    ForElement elseElement = second.elseElement;
-    ForEachPartsWithIdentifier forLoopParts = elseElement.forLoopParts;
+    var elseElement = second.elseElement as ForElement;
+    var forLoopParts = elseElement.forLoopParts as ForEachPartsWithIdentifier;
     expect(forLoopParts.identifier.name, 'a');
 
-    IntegerLiteral forValue = elseElement.body;
+    var forValue = elseElement.body as IntegerLiteral;
     expect(forValue.value, 5);
   }
 
   void test_listLiteral_ifElseSpread() {
-    ListLiteral list =
-        parseCollectionLiteral('[1, if (true) ...[2] else ...?[5]]');
+    var list = parseCollectionLiteral('[1, if (true) ...[2] else ...?[5]]')
+        as ListLiteral;
     expect(list.elements, hasLength(2));
-    IntegerLiteral first = list.elements[0];
+    var first = list.elements[0] as IntegerLiteral;
     expect(first.value, 1);
 
-    IfElement second = list.elements[1];
-    BooleanLiteral condition = second.condition;
+    var second = list.elements[1] as IfElement;
+    var condition = second.condition as BooleanLiteral;
     expect(condition.value, isTrue);
-    SpreadElement thenElement = second.thenElement;
+    var thenElement = second.thenElement as SpreadElement;
     expect(thenElement.spreadOperator.lexeme, '...');
-    SpreadElement elseElement = second.elseElement;
+    var elseElement = second.elseElement as SpreadElement;
     expect(elseElement.spreadOperator.lexeme, '...?');
   }
 
   void test_listLiteral_ifFor() {
-    ListLiteral list = parseCollectionLiteral('[1, if (true) for (a in b) 2]');
+    var list =
+        parseCollectionLiteral('[1, if (true) for (a in b) 2]') as ListLiteral;
     expect(list.elements, hasLength(2));
-    IntegerLiteral first = list.elements[0];
+    var first = list.elements[0] as IntegerLiteral;
     expect(first.value, 1);
 
-    IfElement second = list.elements[1];
-    BooleanLiteral condition = second.condition;
+    var second = list.elements[1] as IfElement;
+    var condition = second.condition as BooleanLiteral;
     expect(condition.value, isTrue);
 
-    ForElement thenElement = second.thenElement;
-    ForEachPartsWithIdentifier forLoopParts = thenElement.forLoopParts;
+    var thenElement = second.thenElement as ForElement;
+    var forLoopParts = thenElement.forLoopParts as ForEachPartsWithIdentifier;
     expect(forLoopParts.identifier.name, 'a');
 
-    IntegerLiteral forValue = thenElement.body;
+    var forValue = thenElement.body as IntegerLiteral;
     expect(forValue.value, 2);
     expect(second.elseElement, isNull);
   }
 
   void test_listLiteral_ifSpread() {
-    ListLiteral list = parseCollectionLiteral('[1, if (true) ...[2]]');
+    var list = parseCollectionLiteral('[1, if (true) ...[2]]') as ListLiteral;
     expect(list.elements, hasLength(2));
-    IntegerLiteral first = list.elements[0];
+    var first = list.elements[0] as IntegerLiteral;
     expect(first.value, 1);
 
-    IfElement second = list.elements[1];
-    BooleanLiteral condition = second.condition;
+    var second = list.elements[1] as IfElement;
+    var condition = second.condition as BooleanLiteral;
     expect(condition.value, isTrue);
-    SpreadElement thenElement = second.thenElement;
+    var thenElement = second.thenElement as SpreadElement;
     expect(thenElement.spreadOperator.lexeme, '...');
     expect(second.elseElement, isNull);
   }
 
   void test_listLiteral_spread() {
-    ListLiteral list = parseCollectionLiteral('[1, ...[2]]');
+    var list = parseCollectionLiteral('[1, ...[2]]') as ListLiteral;
     expect(list.elements, hasLength(2));
-    IntegerLiteral first = list.elements[0];
+    var first = list.elements[0] as IntegerLiteral;
     expect(first.value, 1);
 
-    SpreadElement element = list.elements[1];
+    var element = list.elements[1] as SpreadElement;
     expect(element.spreadOperator.lexeme, '...');
-    ListLiteral spreadExpression = element.expression;
+    var spreadExpression = element.expression as ListLiteral;
     expect(spreadExpression.elements, hasLength(1));
   }
 
   void test_listLiteral_spreadQ() {
-    ListLiteral list = parseCollectionLiteral('[1, ...?[2]]');
+    var list = parseCollectionLiteral('[1, ...?[2]]') as ListLiteral;
     expect(list.elements, hasLength(2));
-    IntegerLiteral first = list.elements[0];
+    var first = list.elements[0] as IntegerLiteral;
     expect(first.value, 1);
 
-    SpreadElement element = list.elements[1];
+    var element = list.elements[1] as SpreadElement;
     expect(element.spreadOperator.lexeme, '...?');
-    ListLiteral spreadExpression = element.expression;
+    var spreadExpression = element.expression as ListLiteral;
     expect(spreadExpression.elements, hasLength(1));
   }
 
   void test_mapLiteral_for() {
-    SetOrMapLiteral map = parseCollectionLiteral(
-        '{1:7, await for (y in list) 2:3}',
-        inAsync: true);
+    var map = parseCollectionLiteral('{1:7, await for (y in list) 2:3}',
+        inAsync: true) as SetOrMapLiteral;
     expect(map.elements, hasLength(2));
-    MapLiteralEntry first = map.elements[0];
-    IntegerLiteral firstValue = first.value;
+    var first = map.elements[0] as MapLiteralEntry;
+    var firstValue = first.value as IntegerLiteral;
     expect(firstValue.value, 7);
 
-    ForElement second = map.elements[1];
+    var second = map.elements[1] as ForElement;
     expect(second.awaitKeyword, isNotNull);
     expect(second.forKeyword.isKeyword, isTrue);
     expect(second.leftParenthesis.lexeme, '(');
     expect(second.rightParenthesis.lexeme, ')');
-    ForEachPartsWithIdentifier forLoopParts = second.forLoopParts;
+    var forLoopParts = second.forLoopParts as ForEachPartsWithIdentifier;
     SimpleIdentifier forLoopVar = forLoopParts.identifier;
     expect(forLoopVar.name, 'y');
     expect(forLoopParts.inKeyword, isNotNull);
-    SimpleIdentifier iterable = forLoopParts.iterable;
+    var iterable = forLoopParts.iterable as SimpleIdentifier;
     expect(iterable.name, 'list');
   }
 
   void test_mapLiteral_forIf() {
-    SetOrMapLiteral map = parseCollectionLiteral(
-        '{1:7, await for (y in list) if (c) 2:3}',
-        inAsync: true);
+    var map = parseCollectionLiteral('{1:7, await for (y in list) if (c) 2:3}',
+        inAsync: true) as SetOrMapLiteral;
     expect(map.elements, hasLength(2));
-    MapLiteralEntry first = map.elements[0];
-    IntegerLiteral firstValue = first.value;
+    var first = map.elements[0] as MapLiteralEntry;
+    var firstValue = first.value as IntegerLiteral;
     expect(firstValue.value, 7);
 
-    ForElement second = map.elements[1];
+    var second = map.elements[1] as ForElement;
     expect(second.awaitKeyword, isNotNull);
     expect(second.forKeyword.isKeyword, isTrue);
     expect(second.leftParenthesis.lexeme, '(');
     expect(second.rightParenthesis.lexeme, ')');
-    ForEachPartsWithIdentifier forLoopParts = second.forLoopParts;
+    var forLoopParts = second.forLoopParts as ForEachPartsWithIdentifier;
     SimpleIdentifier forLoopVar = forLoopParts.identifier;
     expect(forLoopVar.name, 'y');
     expect(forLoopParts.inKeyword, isNotNull);
-    SimpleIdentifier iterable = forLoopParts.iterable;
+    var iterable = forLoopParts.iterable as SimpleIdentifier;
     expect(iterable.name, 'list');
 
-    IfElement body = second.body;
-    SimpleIdentifier condition = body.condition;
+    var body = second.body as IfElement;
+    var condition = body.condition as SimpleIdentifier;
     expect(condition.name, 'c');
-    MapLiteralEntry thenElement = body.thenElement;
-    IntegerLiteral thenValue = thenElement.value;
+    var thenElement = body.thenElement as MapLiteralEntry;
+    var thenValue = thenElement.value as IntegerLiteral;
     expect(thenValue.value, 3);
   }
 
   void test_mapLiteral_forSpread() {
-    SetOrMapLiteral map =
-        parseCollectionLiteral('{1:7, for (x = 0; x < 10; ++x) ...{2:3}}');
+    var map = parseCollectionLiteral('{1:7, for (x = 0; x < 10; ++x) ...{2:3}}')
+        as SetOrMapLiteral;
     expect(map.elements, hasLength(2));
-    MapLiteralEntry first = map.elements[0];
-    IntegerLiteral firstValue = first.value;
+    var first = map.elements[0] as MapLiteralEntry;
+    var firstValue = first.value as IntegerLiteral;
     expect(firstValue.value, 7);
 
-    ForElement second = map.elements[1];
+    var second = map.elements[1] as ForElement;
     expect(second.awaitKeyword, isNull);
     expect(second.forKeyword.isKeyword, isTrue);
     expect(second.leftParenthesis.lexeme, '(');
     expect(second.rightParenthesis.lexeme, ')');
-    ForPartsWithExpression forLoopParts = second.forLoopParts;
-    AssignmentExpression forLoopInit = forLoopParts.initialization;
-    SimpleIdentifier forLoopVar = forLoopInit.leftHandSide;
+    var forLoopParts = second.forLoopParts as ForPartsWithExpression;
+    var forLoopInit = forLoopParts.initialization as AssignmentExpression;
+    var forLoopVar = forLoopInit.leftHandSide as SimpleIdentifier;
     expect(forLoopVar.name, 'x');
-    BinaryExpression condition = forLoopParts.condition;
-    IntegerLiteral rightOperand = condition.rightOperand;
+    var condition = forLoopParts.condition as BinaryExpression;
+    var rightOperand = condition.rightOperand as IntegerLiteral;
     expect(rightOperand.value, 10);
-    PrefixExpression updater = forLoopParts.updaters[0];
-    SimpleIdentifier updaterOperand = updater.operand;
+    var updater = forLoopParts.updaters[0] as PrefixExpression;
+    var updaterOperand = updater.operand as SimpleIdentifier;
     expect(updaterOperand.name, 'x');
   }
 
   void test_mapLiteral_if() {
-    SetOrMapLiteral map = parseCollectionLiteral('{1:1, if (true) 2:4}');
+    var map = parseCollectionLiteral('{1:1, if (true) 2:4}') as SetOrMapLiteral;
     expect(map.elements, hasLength(2));
-    MapLiteralEntry first = map.elements[0];
-    IntegerLiteral firstValue = first.value;
+    var first = map.elements[0] as MapLiteralEntry;
+    var firstValue = first.value as IntegerLiteral;
     expect(firstValue.value, 1);
 
-    IfElement second = map.elements[1];
-    BooleanLiteral condition = second.condition;
+    var second = map.elements[1] as IfElement;
+    var condition = second.condition as BooleanLiteral;
     expect(condition.value, isTrue);
-    MapLiteralEntry thenElement = second.thenElement;
-    IntegerLiteral thenElementValue = thenElement.value;
+    var thenElement = second.thenElement as MapLiteralEntry;
+    var thenElementValue = thenElement.value as IntegerLiteral;
     expect(thenElementValue.value, 4);
     expect(second.elseElement, isNull);
   }
 
   void test_mapLiteral_ifElse() {
-    SetOrMapLiteral map =
-        parseCollectionLiteral('{1:1, if (true) 2:4 else 5:6}');
+    var map = parseCollectionLiteral('{1:1, if (true) 2:4 else 5:6}')
+        as SetOrMapLiteral;
     expect(map.elements, hasLength(2));
-    MapLiteralEntry first = map.elements[0];
-    IntegerLiteral firstValue = first.value;
+    var first = map.elements[0] as MapLiteralEntry;
+    var firstValue = first.value as IntegerLiteral;
     expect(firstValue.value, 1);
 
-    IfElement second = map.elements[1];
-    BooleanLiteral condition = second.condition;
+    var second = map.elements[1] as IfElement;
+    var condition = second.condition as BooleanLiteral;
     expect(condition.value, isTrue);
-    MapLiteralEntry thenElement = second.thenElement;
-    IntegerLiteral thenElementValue = thenElement.value;
+    var thenElement = second.thenElement as MapLiteralEntry;
+    var thenElementValue = thenElement.value as IntegerLiteral;
     expect(thenElementValue.value, 4);
-    MapLiteralEntry elseElement = second.elseElement;
-    IntegerLiteral elseElementValue = elseElement.value;
+    var elseElement = second.elseElement as MapLiteralEntry;
+    var elseElementValue = elseElement.value as IntegerLiteral;
     expect(elseElementValue.value, 6);
   }
 
   void test_mapLiteral_ifElseFor() {
-    SetOrMapLiteral map =
-        parseCollectionLiteral('{1:1, if (true) 2:4 else for (c in d) 5:6}');
+    var map =
+        parseCollectionLiteral('{1:1, if (true) 2:4 else for (c in d) 5:6}')
+            as SetOrMapLiteral;
     expect(map.elements, hasLength(2));
-    MapLiteralEntry first = map.elements[0];
-    IntegerLiteral firstValue = first.value;
+    var first = map.elements[0] as MapLiteralEntry;
+    var firstValue = first.value as IntegerLiteral;
     expect(firstValue.value, 1);
 
-    IfElement second = map.elements[1];
-    BooleanLiteral condition = second.condition;
+    var second = map.elements[1] as IfElement;
+    var condition = second.condition as BooleanLiteral;
     expect(condition.value, isTrue);
-    MapLiteralEntry thenElement = second.thenElement;
-    IntegerLiteral thenElementValue = thenElement.value;
+    var thenElement = second.thenElement as MapLiteralEntry;
+    var thenElementValue = thenElement.value as IntegerLiteral;
     expect(thenElementValue.value, 4);
 
-    ForElement elseElement = second.elseElement;
-    ForEachPartsWithIdentifier forLoopParts = elseElement.forLoopParts;
+    var elseElement = second.elseElement as ForElement;
+    var forLoopParts = elseElement.forLoopParts as ForEachPartsWithIdentifier;
     expect(forLoopParts.identifier.name, 'c');
 
-    MapLiteralEntry body = elseElement.body;
-    IntegerLiteral bodyValue = body.value;
+    var body = elseElement.body as MapLiteralEntry;
+    var bodyValue = body.value as IntegerLiteral;
     expect(bodyValue.value, 6);
   }
 
   void test_mapLiteral_ifElseSpread() {
-    SetOrMapLiteral map =
-        parseCollectionLiteral('{1:7, if (true) ...{2:4} else ...?{5:6}}');
+    var map = parseCollectionLiteral('{1:7, if (true) ...{2:4} else ...?{5:6}}')
+        as SetOrMapLiteral;
     expect(map.elements, hasLength(2));
-    MapLiteralEntry first = map.elements[0];
-    IntegerLiteral firstValue = first.value;
+    var first = map.elements[0] as MapLiteralEntry;
+    var firstValue = first.value as IntegerLiteral;
     expect(firstValue.value, 7);
 
-    IfElement second = map.elements[1];
-    BooleanLiteral condition = second.condition;
+    var second = map.elements[1] as IfElement;
+    var condition = second.condition as BooleanLiteral;
     expect(condition.value, isTrue);
-    SpreadElement thenElement = second.thenElement;
+    var thenElement = second.thenElement as SpreadElement;
     expect(thenElement.spreadOperator.lexeme, '...');
-    SpreadElement elseElement = second.elseElement;
+    var elseElement = second.elseElement as SpreadElement;
     expect(elseElement.spreadOperator.lexeme, '...?');
-    SetOrMapLiteral elseElementExpression = elseElement.expression;
+    var elseElementExpression = elseElement.expression as SetOrMapLiteral;
     expect(elseElementExpression.elements, hasLength(1));
-    MapLiteralEntry entry = elseElementExpression.elements[0];
-    IntegerLiteral entryValue = entry.value;
+    var entry = elseElementExpression.elements[0] as MapLiteralEntry;
+    var entryValue = entry.value as IntegerLiteral;
     expect(entryValue.value, 6);
   }
 
   void test_mapLiteral_ifFor() {
-    SetOrMapLiteral map =
-        parseCollectionLiteral('{1:1, if (true) for (a in b) 2:4}');
+    var map = parseCollectionLiteral('{1:1, if (true) for (a in b) 2:4}')
+        as SetOrMapLiteral;
     expect(map.elements, hasLength(2));
-    MapLiteralEntry first = map.elements[0];
-    IntegerLiteral firstValue = first.value;
+    var first = map.elements[0] as MapLiteralEntry;
+    var firstValue = first.value as IntegerLiteral;
     expect(firstValue.value, 1);
 
-    IfElement second = map.elements[1];
-    BooleanLiteral condition = second.condition;
+    var second = map.elements[1] as IfElement;
+    var condition = second.condition as BooleanLiteral;
     expect(condition.value, isTrue);
 
-    ForElement thenElement = second.thenElement;
-    ForEachPartsWithIdentifier forLoopParts = thenElement.forLoopParts;
+    var thenElement = second.thenElement as ForElement;
+    var forLoopParts = thenElement.forLoopParts as ForEachPartsWithIdentifier;
     expect(forLoopParts.identifier.name, 'a');
 
-    MapLiteralEntry body = thenElement.body;
-    IntegerLiteral thenElementValue = body.value;
+    var body = thenElement.body as MapLiteralEntry;
+    var thenElementValue = body.value as IntegerLiteral;
     expect(thenElementValue.value, 4);
     expect(second.elseElement, isNull);
   }
@@ -883,229 +884,234 @@
   void test_mapLiteral_ifSpread() {
     SetOrMapLiteral map = parseCollectionLiteral('{1:1, if (true) ...{2:4}}');
     expect(map.elements, hasLength(2));
-    MapLiteralEntry first = map.elements[0];
-    IntegerLiteral firstValue = first.value;
+    var first = map.elements[0] as MapLiteralEntry;
+    var firstValue = first.value as IntegerLiteral;
     expect(firstValue.value, 1);
 
-    IfElement second = map.elements[1];
-    BooleanLiteral condition = second.condition;
+    var second = map.elements[1] as IfElement;
+    var condition = second.condition as BooleanLiteral;
     expect(condition.value, isTrue);
-    SpreadElement thenElement = second.thenElement;
+    var thenElement = second.thenElement as SpreadElement;
     expect(thenElement.spreadOperator.lexeme, '...');
     expect(second.elseElement, isNull);
   }
 
   void test_mapLiteral_spread() {
-    SetOrMapLiteral map = parseCollectionLiteral('{1: 2, ...{3: 4}}');
+    var map = parseCollectionLiteral('{1: 2, ...{3: 4}}') as SetOrMapLiteral;
     expect(map.constKeyword, isNull);
     expect(map.typeArguments, isNull);
     expect(map.elements, hasLength(2));
 
-    SpreadElement element = map.elements[1];
+    var element = map.elements[1] as SpreadElement;
     expect(element.spreadOperator.lexeme, '...');
-    SetOrMapLiteral spreadExpression = element.expression;
+    var spreadExpression = element.expression as SetOrMapLiteral;
     expect(spreadExpression.elements, hasLength(1));
   }
 
   void test_mapLiteral_spread2_typed() {
-    SetOrMapLiteral map = parseCollectionLiteral('<int, int>{1: 2, ...{3: 4}}');
+    var map = parseCollectionLiteral('<int, int>{1: 2, ...{3: 4}}')
+        as SetOrMapLiteral;
     expect(map.constKeyword, isNull);
     expect(map.typeArguments.arguments, hasLength(2));
     expect(map.elements, hasLength(2));
 
-    SpreadElement element = map.elements[1];
+    var element = map.elements[1] as SpreadElement;
     expect(element.spreadOperator.lexeme, '...');
-    SetOrMapLiteral spreadExpression = element.expression;
+    var spreadExpression = element.expression as SetOrMapLiteral;
     expect(spreadExpression.elements, hasLength(1));
   }
 
   void test_mapLiteral_spread_typed() {
-    SetOrMapLiteral map = parseCollectionLiteral('<int, int>{...{3: 4}}');
+    var map =
+        parseCollectionLiteral('<int, int>{...{3: 4}}') as SetOrMapLiteral;
     expect(map.constKeyword, isNull);
     expect(map.typeArguments.arguments, hasLength(2));
     expect(map.elements, hasLength(1));
 
-    SpreadElement element = map.elements[0];
+    var element = map.elements[0] as SpreadElement;
     expect(element.spreadOperator.lexeme, '...');
-    SetOrMapLiteral spreadExpression = element.expression;
+    var spreadExpression = element.expression as SetOrMapLiteral;
     expect(spreadExpression.elements, hasLength(1));
   }
 
   void test_mapLiteral_spreadQ() {
-    SetOrMapLiteral map = parseCollectionLiteral('{1: 2, ...?{3: 4}}');
+    var map = parseCollectionLiteral('{1: 2, ...?{3: 4}}') as SetOrMapLiteral;
     expect(map.constKeyword, isNull);
     expect(map.typeArguments, isNull);
     expect(map.elements, hasLength(2));
 
-    SpreadElement element = map.elements[1];
+    var element = map.elements[1] as SpreadElement;
     expect(element.spreadOperator.lexeme, '...?');
-    SetOrMapLiteral spreadExpression = element.expression;
+    var spreadExpression = element.expression as SetOrMapLiteral;
     expect(spreadExpression.elements, hasLength(1));
   }
 
   void test_mapLiteral_spreadQ2_typed() {
-    SetOrMapLiteral map =
-        parseCollectionLiteral('<int, int>{1: 2, ...?{3: 4}}');
+    var map = parseCollectionLiteral('<int, int>{1: 2, ...?{3: 4}}')
+        as SetOrMapLiteral;
     expect(map.constKeyword, isNull);
     expect(map.typeArguments.arguments, hasLength(2));
     expect(map.elements, hasLength(2));
 
-    SpreadElement element = map.elements[1];
+    var element = map.elements[1] as SpreadElement;
     expect(element.spreadOperator.lexeme, '...?');
-    SetOrMapLiteral spreadExpression = element.expression;
+    var spreadExpression = element.expression as SetOrMapLiteral;
     expect(spreadExpression.elements, hasLength(1));
   }
 
   void test_mapLiteral_spreadQ_typed() {
-    SetOrMapLiteral map = parseCollectionLiteral('<int, int>{...?{3: 4}}');
+    var map =
+        parseCollectionLiteral('<int, int>{...?{3: 4}}') as SetOrMapLiteral;
     expect(map.constKeyword, isNull);
     expect(map.typeArguments.arguments, hasLength(2));
     expect(map.elements, hasLength(1));
 
-    SpreadElement element = map.elements[0];
+    var element = map.elements[0] as SpreadElement;
     expect(element.spreadOperator.lexeme, '...?');
-    SetOrMapLiteral spreadExpression = element.expression;
+    var spreadExpression = element.expression as SetOrMapLiteral;
     expect(spreadExpression.elements, hasLength(1));
   }
 
   void test_setLiteral_if() {
-    SetOrMapLiteral setLiteral = parseCollectionLiteral('{1, if (true) 2}');
+    var setLiteral =
+        parseCollectionLiteral('{1, if (true) 2}') as SetOrMapLiteral;
     expect(setLiteral.elements, hasLength(2));
-    IntegerLiteral first = setLiteral.elements[0];
+    var first = setLiteral.elements[0] as IntegerLiteral;
     expect(first.value, 1);
 
-    IfElement second = setLiteral.elements[1];
-    BooleanLiteral condition = second.condition;
+    var second = setLiteral.elements[1] as IfElement;
+    var condition = second.condition as BooleanLiteral;
     expect(condition.value, isTrue);
-    IntegerLiteral thenElement = second.thenElement;
+    var thenElement = second.thenElement as IntegerLiteral;
     expect(thenElement.value, 2);
     expect(second.elseElement, isNull);
   }
 
   void test_setLiteral_ifElse() {
-    SetOrMapLiteral setLiteral =
-        parseCollectionLiteral('{1, if (true) 2 else 5}');
+    var setLiteral =
+        parseCollectionLiteral('{1, if (true) 2 else 5}') as SetOrMapLiteral;
     expect(setLiteral.elements, hasLength(2));
-    IntegerLiteral first = setLiteral.elements[0];
+    var first = setLiteral.elements[0] as IntegerLiteral;
     expect(first.value, 1);
 
-    IfElement second = setLiteral.elements[1];
-    BooleanLiteral condition = second.condition;
+    var second = setLiteral.elements[1] as IfElement;
+    var condition = second.condition as BooleanLiteral;
     expect(condition.value, isTrue);
-    IntegerLiteral thenElement = second.thenElement;
+    var thenElement = second.thenElement as IntegerLiteral;
     expect(thenElement.value, 2);
-    IntegerLiteral elseElement = second.elseElement;
+    var elseElement = second.elseElement as IntegerLiteral;
     expect(elseElement.value, 5);
   }
 
   void test_setLiteral_ifElseSpread() {
-    SetOrMapLiteral setLiteral =
-        parseCollectionLiteral('{1, if (true) ...{2} else ...?[5]}');
+    var setLiteral =
+        parseCollectionLiteral('{1, if (true) ...{2} else ...?[5]}')
+            as SetOrMapLiteral;
     expect(setLiteral.elements, hasLength(2));
-    IntegerLiteral first = setLiteral.elements[0];
+    var first = setLiteral.elements[0] as IntegerLiteral;
     expect(first.value, 1);
 
-    IfElement second = setLiteral.elements[1];
-    BooleanLiteral condition = second.condition;
+    var second = setLiteral.elements[1] as IfElement;
+    var condition = second.condition as BooleanLiteral;
     expect(condition.value, isTrue);
-    SpreadElement thenElement = second.thenElement;
+    var thenElement = second.thenElement as SpreadElement;
     expect(thenElement.spreadOperator.lexeme, '...');
-    SetOrMapLiteral theExpression = thenElement.expression;
+    var theExpression = thenElement.expression as SetOrMapLiteral;
     expect(theExpression.elements, hasLength(1));
-    SpreadElement elseElement = second.elseElement;
+    var elseElement = second.elseElement as SpreadElement;
     expect(elseElement.spreadOperator.lexeme, '...?');
-    ListLiteral elseExpression = elseElement.expression;
+    var elseExpression = elseElement.expression as ListLiteral;
     expect(elseExpression.elements, hasLength(1));
   }
 
   void test_setLiteral_ifSpread() {
-    SetOrMapLiteral setLiteral =
-        parseCollectionLiteral('{1, if (true) ...[2]}');
+    var setLiteral =
+        parseCollectionLiteral('{1, if (true) ...[2]}') as SetOrMapLiteral;
     expect(setLiteral.elements, hasLength(2));
-    IntegerLiteral first = setLiteral.elements[0];
+    var first = setLiteral.elements[0] as IntegerLiteral;
     expect(first.value, 1);
 
-    IfElement second = setLiteral.elements[1];
-    BooleanLiteral condition = second.condition;
+    var second = setLiteral.elements[1] as IfElement;
+    var condition = second.condition as BooleanLiteral;
     expect(condition.value, isTrue);
-    SpreadElement thenElement = second.thenElement;
+    var thenElement = second.thenElement as SpreadElement;
     expect(thenElement.spreadOperator.lexeme, '...');
     expect(second.elseElement, isNull);
   }
 
   void test_setLiteral_spread2() {
-    SetOrMapLiteral set = parseCollectionLiteral('{3, ...[4]}');
+    var set = parseCollectionLiteral('{3, ...[4]}') as SetOrMapLiteral;
     expect(set.constKeyword, isNull);
     expect(set.typeArguments, isNull);
     expect(set.elements, hasLength(2));
-    IntegerLiteral value = set.elements[0];
+    var value = set.elements[0] as IntegerLiteral;
     expect(value.value, 3);
 
-    SpreadElement element = set.elements[1];
+    var element = set.elements[1] as SpreadElement;
     expect(element.spreadOperator.lexeme, '...');
-    ListLiteral spreadExpression = element.expression;
+    var spreadExpression = element.expression as ListLiteral;
     expect(spreadExpression.elements, hasLength(1));
   }
 
   void test_setLiteral_spread2Q() {
-    SetOrMapLiteral set = parseCollectionLiteral('{3, ...?[4]}');
+    var set = parseCollectionLiteral('{3, ...?[4]}') as SetOrMapLiteral;
     expect(set.constKeyword, isNull);
     expect(set.typeArguments, isNull);
     expect(set.elements, hasLength(2));
-    IntegerLiteral value = set.elements[0];
+    var value = set.elements[0] as IntegerLiteral;
     expect(value.value, 3);
 
-    SpreadElement element = set.elements[1];
+    var element = set.elements[1] as SpreadElement;
     expect(element.spreadOperator.lexeme, '...?');
-    ListLiteral spreadExpression = element.expression;
+    var spreadExpression = element.expression as ListLiteral;
     expect(spreadExpression.elements, hasLength(1));
   }
 
   void test_setLiteral_spread_typed() {
-    SetOrMapLiteral set = parseCollectionLiteral('<int>{...[3]}');
+    var set = parseCollectionLiteral('<int>{...[3]}') as SetOrMapLiteral;
     expect(set.constKeyword, isNull);
     expect(set.typeArguments, isNotNull);
     expect(set.elements, hasLength(1));
 
-    SpreadElement element = set.elements[0];
+    var element = set.elements[0] as SpreadElement;
     expect(element.spreadOperator.lexeme, '...');
-    ListLiteral spreadExpression = element.expression;
+    var spreadExpression = element.expression as ListLiteral;
     expect(spreadExpression.elements, hasLength(1));
   }
 
   void test_setLiteral_spreadQ_typed() {
-    SetOrMapLiteral set = parseCollectionLiteral('<int>{...?[3]}');
+    var set = parseCollectionLiteral('<int>{...?[3]}') as SetOrMapLiteral;
     expect(set.constKeyword, isNull);
     expect(set.typeArguments, isNotNull);
     expect(set.elements, hasLength(1));
 
-    SpreadElement element = set.elements[0];
+    var element = set.elements[0] as SpreadElement;
     expect(element.spreadOperator.lexeme, '...?');
-    ListLiteral spreadExpression = element.expression;
+    var spreadExpression = element.expression as ListLiteral;
     expect(spreadExpression.elements, hasLength(1));
   }
 
   void test_setOrMapLiteral_spread() {
-    SetOrMapLiteral map = parseCollectionLiteral('{...{3: 4}}');
+    var map = parseCollectionLiteral('{...{3: 4}}') as SetOrMapLiteral;
     expect(map.constKeyword, isNull);
     expect(map.typeArguments, isNull);
     expect(map.elements, hasLength(1));
 
-    SpreadElement element = map.elements[0];
+    var element = map.elements[0] as SpreadElement;
     expect(element.spreadOperator.lexeme, '...');
-    SetOrMapLiteral spreadExpression = element.expression;
+    var spreadExpression = element.expression as SetOrMapLiteral;
     expect(spreadExpression.elements, hasLength(1));
   }
 
   void test_setOrMapLiteral_spreadQ() {
-    SetOrMapLiteral map = parseCollectionLiteral('{...?{3: 4}}');
+    var map = parseCollectionLiteral('{...?{3: 4}}') as SetOrMapLiteral;
     expect(map.constKeyword, isNull);
     expect(map.typeArguments, isNull);
     expect(map.elements, hasLength(1));
 
-    SpreadElement element = map.elements[0];
+    var element = map.elements[0] as SpreadElement;
     expect(element.spreadOperator.lexeme, '...?');
-    SetOrMapLiteral spreadExpression = element.expression;
+    var spreadExpression = element.expression as SetOrMapLiteral;
     expect(spreadExpression.elements, hasLength(1));
   }
 }
@@ -1115,21 +1121,22 @@
 class ComplexParserTest_Fasta extends FastaParserTestCase
     with ComplexParserTestMixin {
   void test_binary_operator_written_out_expression() {
-    BinaryExpression expression = parseExpression('x xor y', errors: [
+    var expression = parseExpression('x xor y', errors: [
       expectedError(ParserErrorCode.BINARY_OPERATOR_WRITTEN_OUT, 2, 3),
-    ]);
-    SimpleIdentifier lhs = expression.leftOperand;
+    ]) as BinaryExpression;
+    var lhs = expression.leftOperand as SimpleIdentifier;
     expect(lhs.name, 'x');
     expect(expression.operator.lexeme, '^');
-    SimpleIdentifier rhs = expression.rightOperand;
+    var rhs = expression.rightOperand as SimpleIdentifier;
     expect(rhs.name, 'y');
   }
 
   void test_conditionalExpression_precedence_nullableType_as2() {
-    ExpressionStatement statement = parseStatement('x as bool? ? (x + y) : z;');
-    ConditionalExpression expression = statement.expression;
-    AsExpression asExpression = expression.condition;
-    TypeName type = asExpression.type;
+    var statement =
+        parseStatement('x as bool? ? (x + y) : z;') as ExpressionStatement;
+    var expression = statement.expression as ConditionalExpression;
+    var asExpression = expression.condition as AsExpression;
+    var type = asExpression.type as TypeName;
     expect(type.question.lexeme, '?');
     Expression thenExpression = expression.thenExpression;
     expect(thenExpression, isParenthesizedExpression);
@@ -1140,12 +1147,12 @@
   }
 
   void test_conditionalExpression_precedence_nullableType_as3() {
-    ExpressionStatement statement =
-        parseStatement('(x as bool?) ? (x + y) : z;');
-    ConditionalExpression expression = statement.expression;
-    ParenthesizedExpression condition = expression.condition;
-    AsExpression asExpression = condition.expression;
-    TypeName type = asExpression.type;
+    var statement =
+        parseStatement('(x as bool?) ? (x + y) : z;') as ExpressionStatement;
+    var expression = statement.expression as ConditionalExpression;
+    var condition = expression.condition as ParenthesizedExpression;
+    var asExpression = condition.expression as AsExpression;
+    var type = asExpression.type as TypeName;
     expect(type.question.lexeme, '?');
     Expression thenExpression = expression.thenExpression;
     expect(thenExpression, isParenthesizedExpression);
@@ -1156,11 +1163,11 @@
   }
 
   void test_conditionalExpression_precedence_nullableType_is2() {
-    ExpressionStatement statement =
-        parseStatement('x is String? ? (x + y) : z;');
-    ConditionalExpression expression = statement.expression;
-    IsExpression isExpression = expression.condition;
-    TypeName type = isExpression.type;
+    var statement =
+        parseStatement('x is String? ? (x + y) : z;') as ExpressionStatement;
+    var expression = statement.expression as ConditionalExpression;
+    var isExpression = expression.condition as IsExpression;
+    var type = isExpression.type as TypeName;
     expect(type.question.lexeme, '?');
     Expression thenExpression = expression.thenExpression;
     expect(thenExpression, isParenthesizedExpression);
@@ -1171,12 +1178,12 @@
   }
 
   void test_conditionalExpression_precedence_nullableType_is3() {
-    ExpressionStatement statement =
-        parseStatement('(x is String?) ? (x + y) : z;');
-    ConditionalExpression expression = statement.expression;
-    ParenthesizedExpression condition = expression.condition;
-    IsExpression isExpression = condition.expression;
-    TypeName type = isExpression.type;
+    var statement =
+        parseStatement('(x is String?) ? (x + y) : z;') as ExpressionStatement;
+    var expression = statement.expression as ConditionalExpression;
+    var condition = expression.condition as ParenthesizedExpression;
+    var isExpression = condition.expression as IsExpression;
+    var type = isExpression.type as TypeName;
     expect(type.question.lexeme, '?');
     Expression thenExpression = expression.thenExpression;
     expect(thenExpression, isParenthesizedExpression);
@@ -1447,53 +1454,53 @@
 
   void test_lt_dot_bracket_quote() {
     // https://github.com/dart-lang/sdk/issues/37674
-    ListLiteral list = parseExpression('<.["', errors: [
+    var list = parseExpression('<.["', errors: [
       expectedError(ParserErrorCode.EXPECTED_TYPE_NAME, 1, 1),
       expectedError(ParserErrorCode.EXPECTED_TYPE_NAME, 2, 1),
       expectedError(ScannerErrorCode.UNTERMINATED_STRING_LITERAL, 3, 1),
       expectedError(ScannerErrorCode.EXPECTED_TOKEN, 4, 1),
-    ]);
+    ]) as ListLiteral;
     expect(list.elements, hasLength(1));
-    StringLiteral first = list.elements[0];
+    var first = list.elements[0] as StringLiteral;
     expect(first.length, 1);
   }
 
   void test_lt_dot_listLiteral() {
     // https://github.com/dart-lang/sdk/issues/37674
-    ListLiteral list = parseExpression('<.[]', errors: [
+    var list = parseExpression('<.[]', errors: [
       expectedError(ParserErrorCode.EXPECTED_TYPE_NAME, 1, 1),
       expectedError(ParserErrorCode.EXPECTED_TYPE_NAME, 2, 2),
-    ]);
+    ]) as ListLiteral;
     expect(list.elements, hasLength(0));
   }
 
   void test_mapLiteral() {
-    SetOrMapLiteral map = parseExpression('{3: 6}');
+    var map = parseExpression('{3: 6}') as SetOrMapLiteral;
     expect(map.constKeyword, isNull);
     expect(map.typeArguments, isNull);
     expect(map.elements, hasLength(1));
-    MapLiteralEntry entry = map.elements[0];
-    IntegerLiteral key = entry.key;
+    var entry = map.elements[0] as MapLiteralEntry;
+    var key = entry.key as IntegerLiteral;
     expect(key.value, 3);
-    IntegerLiteral value = entry.value;
+    var value = entry.value as IntegerLiteral;
     expect(value.value, 6);
   }
 
   void test_mapLiteral_const() {
-    SetOrMapLiteral map = parseExpression('const {3: 6}');
+    var map = parseExpression('const {3: 6}') as SetOrMapLiteral;
     expect(map.constKeyword, isNotNull);
     expect(map.typeArguments, isNull);
     expect(map.elements, hasLength(1));
-    MapLiteralEntry entry = map.elements[0];
-    IntegerLiteral key = entry.key;
+    var entry = map.elements[0] as MapLiteralEntry;
+    var key = entry.key as IntegerLiteral;
     expect(key.value, 3);
-    IntegerLiteral value = entry.value;
+    var value = entry.value as IntegerLiteral;
     expect(value.value, 6);
   }
 
   @failingTest
   void test_mapLiteral_invalid_too_many_type_arguments1() {
-    SetOrMapLiteral map = parseExpression('<int, int, int>{}', errors: [
+    var map = parseExpression('<int, int, int>{}', errors: [
       // TODO(danrubel): Currently the resolver reports invalid number of
       // type arguments, but the parser could report this.
       expectedError(
@@ -1501,14 +1508,14 @@
           ParserErrorCode.EXPECTED_TOKEN,
           11,
           3),
-    ]);
+    ]) as SetOrMapLiteral;
     expect(map.constKeyword, isNull);
     expect(map.elements, hasLength(0));
   }
 
   @failingTest
   void test_mapLiteral_invalid_too_many_type_arguments2() {
-    SetOrMapLiteral map = parseExpression('<int, int, int>{1}', errors: [
+    var map = parseExpression('<int, int, int>{1}', errors: [
       // TODO(danrubel): Currently the resolver reports invalid number of
       // type arguments, but the parser could report this.
       expectedError(
@@ -1516,7 +1523,7 @@
           ParserErrorCode.EXPECTED_TOKEN,
           11,
           3),
-    ]);
+    ]) as SetOrMapLiteral;
     expect(map.constKeyword, isNull);
     expect(map.elements, hasLength(0));
   }
@@ -1535,7 +1542,7 @@
       expectedError(ParserErrorCode.EXPECTED_IDENTIFIER_BUT_GOT_KEYWORD, 8, 4)
     ]);
     expect(expression, isStringInterpolation);
-    StringInterpolation literal = expression;
+    var literal = expression as StringInterpolation;
     NodeList<InterpolationElement> elements = literal.elements;
     expect(elements, hasLength(3));
     expect(elements[0] is InterpolationString, isTrue);
diff --git a/pkg/analyzer/test/generated/source_factory_test.dart b/pkg/analyzer/test/generated/source_factory_test.dart
index 3f89277..3ec4b21 100644
--- a/pkg/analyzer/test/generated/source_factory_test.dart
+++ b/pkg/analyzer/test/generated/source_factory_test.dart
@@ -40,15 +40,6 @@
   }
 }
 
-class CustomUriResolver extends UriResolver {
-  String uriPath;
-  CustomUriResolver({this.uriPath});
-
-  @override
-  Source resolveAbsolute(Uri uri, [Uri actualUri]) =>
-      createSource(path: uriPath);
-}
-
 @reflectiveTest
 class SourceFactoryTest with ResourceProviderMixin {
   void test_creation() {
diff --git a/pkg/analyzer/test/generated/utilities_test.dart b/pkg/analyzer/test/generated/utilities_test.dart
index 78ad197..1bb1df6 100644
--- a/pkg/analyzer/test/generated/utilities_test.dart
+++ b/pkg/analyzer/test/generated/utilities_test.dart
@@ -1165,14 +1165,14 @@
 
   Expression _parseExpression(String code) {
     CompilationUnit unit = _parseUnit('var v = $code;');
-    TopLevelVariableDeclaration decl = unit.declarations.single;
+    var decl = unit.declarations.single as TopLevelVariableDeclaration;
     return decl.variables.variables.single.initializer;
   }
 
   Statement _parseStatement(String code) {
     CompilationUnit unit = _parseUnit('main() async { $code }');
-    FunctionDeclaration main = unit.declarations.single;
-    BlockFunctionBody body = main.functionExpression.body;
+    var main = unit.declarations.single as FunctionDeclaration;
+    var body = main.functionExpression.body as BlockFunctionBody;
     return body.block.statements.single;
   }
 
diff --git a/pkg/analyzer/test/src/dart/ast/ast_test.dart b/pkg/analyzer/test/src/dart/ast/ast_test.dart
index 8ab94b5..bb96a03 100644
--- a/pkg/analyzer/test/src/dart/ast/ast_test.dart
+++ b/pkg/analyzer/test/src/dart/ast/ast_test.dart
@@ -21,8 +21,8 @@
 
 @reflectiveTest
 class CompilationUnitImplTest extends ParserTestCase {
-  String testSource;
-  CompilationUnitImpl testUnit;
+  /*late*/ String testSource;
+  /*late*/ CompilationUnitImpl testUnit;
 
   parse(String source) {
     testSource = source;
@@ -84,7 +84,7 @@
     int index = testSource.indexOf(snippet);
     expect(index >= 0, isTrue);
     NodeLocator visitor = NodeLocator(index);
-    AstNodeImpl node = visitor.searchWithin(testUnit);
+    var node = visitor.searchWithin(testUnit) as AstNodeImpl;
     expect(node, TypeMatcher<ExpressionImpl>());
     expect((node as ExpressionImpl).inConstantContext,
         isInContext ? isTrue : isFalse);
diff --git a/pkg/analyzer/test/src/dart/ast/constant_evaluator_test.dart b/pkg/analyzer/test/src/dart/ast/constant_evaluator_test.dart
index ac0dc66..dfa42c6 100644
--- a/pkg/analyzer/test/src/dart/ast/constant_evaluator_test.dart
+++ b/pkg/analyzer/test/src/dart/ast/constant_evaluator_test.dart
@@ -18,17 +18,17 @@
 @reflectiveTest
 class ConstantEvaluatorTest extends ParseBase {
   void test_binary_bitAnd() {
-    int value = _getConstantValue("74 & 42");
+    var value = _getConstantValue("74 & 42") as int;
     expect(value, 74 & 42);
   }
 
   void test_binary_bitOr() {
-    int value = _getConstantValue("74 | 42");
+    var value = _getConstantValue("74 | 42") as int;
     expect(value, 74 | 42);
   }
 
   void test_binary_bitXor() {
-    int value = _getConstantValue("74 ^ 42");
+    var value = _getConstantValue("74 ^ 42") as int;
     expect(value, 74 ^ 42);
   }
 
@@ -78,7 +78,7 @@
   }
 
   void test_binary_leftShift() {
-    int value = _getConstantValue("16 << 2");
+    var value = _getConstantValue("16 << 2") as int;
     expect(value, 64);
   }
 
@@ -183,7 +183,7 @@
   }
 
   void test_binary_rightShift() {
-    int value = _getConstantValue("64 >> 2");
+    var value = _getConstantValue("64 >> 2") as int;
     expect(value, 16);
   }
 
@@ -198,12 +198,12 @@
   }
 
   void test_binary_truncatingDivide_double() {
-    int value = _getConstantValue("3.2 ~/ 2.3");
+    var value = _getConstantValue("3.2 ~/ 2.3") as int;
     expect(value, 1);
   }
 
   void test_binary_truncatingDivide_integer() {
-    int value = _getConstantValue("10 ~/ 3");
+    var value = _getConstantValue("10 ~/ 3") as int;
     expect(value, 3);
   }
 
@@ -260,7 +260,7 @@
   }
 
   void test_literal_list() {
-    List value = _getConstantValue("['a', 'b', 'c']");
+    var value = _getConstantValue("['a', 'b', 'c']") as List<Object>;
     expect(value.length, 3);
     expect(value[0], "a");
     expect(value[1], "b");
@@ -268,7 +268,8 @@
   }
 
   void test_literal_map() {
-    Map value = _getConstantValue("{'a' : 'm', 'b' : 'n', 'c' : 'o'}");
+    var value = _getConstantValue("{'a' : 'm', 'b' : 'n', 'c' : 'o'}")
+        as Map<Object, Object>;
     expect(value.length, 3);
     expect(value["a"], "m");
     expect(value["b"], "n");
@@ -316,7 +317,7 @@
   }
 
   void test_unary_bitNot() {
-    int value = _getConstantValue("~42");
+    var value = _getConstantValue("~42") as int;
     expect(value, ~42);
   }
 
diff --git a/pkg/analyzer/test/src/dart/ast/to_source_visitor_test.dart b/pkg/analyzer/test/src/dart/ast/to_source_visitor_test.dart
index 4fe02d3..2898bae 100644
--- a/pkg/analyzer/test/src/dart/ast/to_source_visitor_test.dart
+++ b/pkg/analyzer/test/src/dart/ast/to_source_visitor_test.dart
@@ -987,8 +987,8 @@
   }
 
   void test_visitFieldFormalParameter_type_covariant() {
-    FieldFormalParameterImpl expected = AstTestFactory.fieldFormalParameter(
-        null, AstTestFactory.typeName4("A"), "a");
+    var expected = AstTestFactory.fieldFormalParameter(
+        null, AstTestFactory.typeName4("A"), "a") as FieldFormalParameterImpl;
     expected.covariantKeyword =
         TokenFactory.tokenFromKeyword(Keyword.COVARIANT);
     _assertSource("covariant A this.a", expected);
@@ -1570,9 +1570,8 @@
   }
 
   void test_visitFunctionTypedFormalParameter_type_covariant() {
-    FunctionTypedFormalParameterImpl expected =
-        AstTestFactory.functionTypedFormalParameter(
-            AstTestFactory.typeName4("T"), "f");
+    var expected = AstTestFactory.functionTypedFormalParameter(
+        AstTestFactory.typeName4("T"), "f") as FunctionTypedFormalParameterImpl;
     expected.covariantKeyword =
         TokenFactory.tokenFromKeyword(Keyword.COVARIANT);
     _assertSource("covariant T f()", expected);
@@ -2471,8 +2470,8 @@
   }
 
   void test_visitSimpleFormalParameter_type_covariant() {
-    SimpleFormalParameterImpl expected = AstTestFactory.simpleFormalParameter4(
-        AstTestFactory.typeName4("A"), "a");
+    var expected = AstTestFactory.simpleFormalParameter4(
+        AstTestFactory.typeName4("A"), "a") as SimpleFormalParameterImpl;
     expected.covariantKeyword =
         TokenFactory.tokenFromKeyword(Keyword.COVARIANT);
     _assertSource("covariant A a", expected);
diff --git a/pkg/analyzer/test/src/dart/ast/utilities_test.dart b/pkg/analyzer/test/src/dart/ast/utilities_test.dart
index 7ffec93..f0b6733 100644
--- a/pkg/analyzer/test/src/dart/ast/utilities_test.dart
+++ b/pkg/analyzer/test/src/dart/ast/utilities_test.dart
@@ -37,7 +37,7 @@
     String code = ' int vv; ';
     //             012345678
     CompilationUnit unit = parseCompilationUnit(code);
-    TopLevelVariableDeclaration declaration = unit.declarations[0];
+    var declaration = unit.declarations[0] as TopLevelVariableDeclaration;
     VariableDeclarationList variableList = declaration.variables;
     Identifier typeName = (variableList.type as TypeName).name;
     SimpleIdentifier varName = variableList.variables[0].name;
@@ -58,7 +58,7 @@
     String code = ' int vv; ';
     //             012345678
     CompilationUnit unit = parseCompilationUnit(code);
-    TopLevelVariableDeclaration declaration = unit.declarations[0];
+    var declaration = unit.declarations[0] as TopLevelVariableDeclaration;
     VariableDeclarationList variableList = declaration.variables;
     Identifier typeName = (variableList.type as TypeName).name;
     SimpleIdentifier varName = variableList.variables[0].name;
@@ -277,11 +277,11 @@
   void test_visitConstructorDeclaration() {
     String className = "A";
     String constructorName = "c";
-    ConstructorDeclarationImpl fromNode = AstTestFactory.constructorDeclaration(
+    var fromNode = AstTestFactory.constructorDeclaration(
         AstTestFactory.identifier3(className),
         constructorName,
         AstTestFactory.formalParameterList(),
-        null);
+        null) as ConstructorDeclarationImpl;
     ConstructorElement element = ElementFactory.constructorElement2(
         ElementFactory.classElement2(className), constructorName);
     fromNode.declaredElement = element;
@@ -472,7 +472,7 @@
     DartType typeC = interfaceTypeStar(ElementFactory.classElement2('C'));
 
     ForStatement fromNode = createNode();
-    ForEachPartsWithIdentifier fromForLoopParts = fromNode.forLoopParts;
+    var fromForLoopParts = fromNode.forLoopParts as ForEachPartsWithIdentifier;
     fromForLoopParts.identifier.staticType = typeA;
     (fromForLoopParts.iterable as SimpleIdentifier).staticType = typeB;
     ((fromNode.body as ExpressionStatement).expression as SimpleIdentifier)
@@ -480,7 +480,7 @@
 
     ForStatement toNode = createNode();
     ResolutionCopier.copyResolutionData(fromNode, toNode);
-    ForEachPartsWithIdentifier toForLoopParts = fromNode.forLoopParts;
+    var toForLoopParts = fromNode.forLoopParts as ForEachPartsWithIdentifier;
     expect(toForLoopParts.identifier.staticType, same(typeA));
     expect(
         (toForLoopParts.iterable as SimpleIdentifier).staticType, same(typeB));
@@ -491,9 +491,9 @@
   }
 
   void test_visitFunctionExpression() {
-    FunctionExpressionImpl fromNode = AstTestFactory.functionExpression2(
+    var fromNode = AstTestFactory.functionExpression2(
         AstTestFactory.formalParameterList(),
-        AstTestFactory.emptyFunctionBody());
+        AstTestFactory.emptyFunctionBody()) as FunctionExpressionImpl;
     MethodElement element = ElementFactory.methodElement(
         "m", interfaceTypeStar(ElementFactory.classElement2('C')));
     fromNode.declaredElement = element;
diff --git a/pkg/dartdev/lib/src/experiments.dart b/pkg/dartdev/lib/src/experiments.dart
index ebbff07..36d4bd8 100644
--- a/pkg/dartdev/lib/src/experiments.dart
+++ b/pkg/dartdev/lib/src/experiments.dart
@@ -39,13 +39,22 @@
 extension EnabledExperimentsArg on ArgResults {
   List<String> get enabledExperiments {
     List<String> enabledExperiments = [];
+    // Check to see if the ArgParser which generated this result accepts
+    // --enable-experiment as an option. If so, return the result if it was
+    // provided.
     if (options.contains(experimentFlagName)) {
       if (wasParsed(experimentFlagName)) {
         enabledExperiments = this[experimentFlagName];
       }
     } else {
-      String experiments = arguments.firstWhere(
-        (e) => e.startsWith('--enable-experiment'),
+      // In the case where a command uses ArgParser.allowAnything() as its
+      // parser the valid set of options for the command isn't specified and
+      // isn't enforced. Instead, we have to manually parse the arguments to
+      // look for --enable-experiment=. Currently, this path is only taken for
+      // the pub and test commands, as well as when we are trying to send
+      // analytics.
+      final String experiments = arguments.firstWhere(
+        (e) => e.startsWith('--enable-experiment='),
         orElse: () => null,
       );
       if (experiments == null) {
diff --git a/pkg/dds/CHANGELOG.md b/pkg/dds/CHANGELOG.md
index f959b95..32be6a6 100644
--- a/pkg/dds/CHANGELOG.md
+++ b/pkg/dds/CHANGELOG.md
@@ -1,3 +1,8 @@
+# 1.5.0
+- Added event caching for `Stdout`, `Stderr`, and `Extension` streams. When a
+client subscribes to one of these streams, they will be sent up to 10,000
+historical events from the stream.
+
 # 1.4.1
 - Fixed issue where `evaluate` and `evaluateInFrame` requests were not being
   forwarded to the VM service properly when no external compilation service
diff --git a/pkg/dds/dds_protocol.md b/pkg/dds/dds_protocol.md
index be9da7e..253ef99 100644
--- a/pkg/dds/dds_protocol.md
+++ b/pkg/dds/dds_protocol.md
@@ -47,6 +47,22 @@
 
 See the corresponding section in the VM Service protocol [here][service-protocol-ids-and-names].
 
+## Streams
+
+For a list of core VM service streams, see [streamListen][service-protocol-streams].
+
+DDS will keep a history of events on certain streams and send historical events
+when a client first subscribes to a stream with history. These streams currently
+consist of the following:
+
+- `Logging`
+- `Stdout`
+- `Stderr`
+- `Extension`
+
+In addition, subscribing to the `Service` stream will result in a `ServiceRegistered`
+event being sent to the subscribing client for each existing service extension.
+
 ## Public RPCs
 
 The DDS Protocol supports all [public RPCs defined in the VM Service protocol][service-protocol-public-rpcs].
@@ -187,6 +203,7 @@
 [service-protocol]: https://github.com/dart-lang/sdk/blob/master/runtime/vm/service/service.md
 [service-protocol-rpcs-requests-and-responses]: https://github.com/dart-lang/sdk/blob/master/runtime/vm/service/service.md#rpcs-requests-and-responses
 [service-protocol-events]: https://github.com/dart-lang/sdk/blob/master/runtime/vm/service/service.md#events
+[service-protocol-streams]: https://github.com/dart-lang/sdk/blob/master/runtime/vm/service/service.md#streamlisten
 [service-protocol-binary-events]: https://github.com/dart-lang/sdk/blob/master/runtime/vm/service/service.md#binary-events
 [service-protocol-types]: https://github.com/dart-lang/sdk/blob/master/runtime/vm/service/service.md#types
 [service-protocol-ids-and-names]: https://github.com/dart-lang/sdk/blob/master/runtime/vm/service/service.md#ids-and-names
diff --git a/pkg/dds/lib/src/client.dart b/pkg/dds/lib/src/client.dart
index 79e4233..2c85aae 100644
--- a/pkg/dds/lib/src/client.dart
+++ b/pkg/dds/lib/src/client.dart
@@ -140,7 +140,9 @@
         'getLogHistorySize',
         (parameters) => {
               'type': 'Size',
-              'size': dds.loggingRepository.bufferSize,
+              'size': _StreamManager
+                  .loggingRepositories[_StreamManager.kLoggingStream]
+                  .bufferSize,
             });
 
     _clientPeer.registerMethod('setLogHistorySize', (parameters) {
@@ -150,7 +152,8 @@
           "'size' must be greater or equal to zero",
         );
       }
-      dds.loggingRepository.resize(size);
+      _StreamManager.loggingRepositories[_StreamManager.kLoggingStream]
+          .resize(size);
       return _RPCResponses.success;
     });
 
diff --git a/pkg/dds/lib/src/dds_impl.dart b/pkg/dds/lib/src/dds_impl.dart
index 06327a8..d2a6dcb 100644
--- a/pkg/dds/lib/src/dds_impl.dart
+++ b/pkg/dds/lib/src/dds_impl.dart
@@ -10,7 +10,6 @@
     _clientManager = _ClientManager(this);
     _expressionEvaluator = _ExpressionEvaluator(this);
     _isolateManager = _IsolateManager(this);
-    _loggingRepository = _LoggingRepository();
     _streamManager = _StreamManager(this);
     _authCode = _authCodesEnabled ? _makeAuthToken() : '';
   }
@@ -270,9 +269,6 @@
   _IsolateManager get isolateManager => _isolateManager;
   _IsolateManager _isolateManager;
 
-  _LoggingRepository get loggingRepository => _loggingRepository;
-  _LoggingRepository _loggingRepository;
-
   _StreamManager get streamManager => _streamManager;
   _StreamManager _streamManager;
 
diff --git a/pkg/dds/lib/src/stream_manager.dart b/pkg/dds/lib/src/stream_manager.dart
index abb233c..542fe91 100644
--- a/pkg/dds/lib/src/stream_manager.dart
+++ b/pkg/dds/lib/src/stream_manager.dart
@@ -91,7 +91,14 @@
     // The _IsolateManager requires information from both the Debug and
     // Isolate streams, so they must always be subscribed to by DDS.
     for (final stream in ddsCoreStreams) {
-      await streamListen(null, stream);
+      try {
+        await streamListen(null, stream);
+        if (loggingRepositoryStreams.contains(stream)) {
+          loggingRepositories[stream] = _LoggingRepository();
+        }
+      } on json_rpc.RpcException {
+        // Stdout and Stderr streams may not exist.
+      }
     }
     dds._vmServiceClient.registerMethod(
       'streamNotify',
@@ -101,10 +108,10 @@
         if (isolateManagerStreams.contains(streamId)) {
           dds.isolateManager.handleIsolateEvent(parameters);
         }
-        // Keep a history of log messages to send to clients when they first
-        // subscribe to the Logging stream.
-        if (streamId == kLoggingStream) {
-          dds.loggingRepository.add(parameters.asMap);
+        // Keep a history of messages to send to clients when they first
+        // subscribe to a stream with an event history.
+        if (loggingRepositories.containsKey(streamId)) {
+          loggingRepositories[streamId].add(parameters.asMap);
         }
         streamNotify(streamId, parameters.value);
       },
@@ -137,8 +144,8 @@
     }
     if (client != null) {
       streamListeners[stream].add(client);
-      if (stream == kLoggingStream) {
-        dds.loggingRepository.sendHistoricalLogs(client);
+      if (loggingRepositories.containsKey(stream)) {
+        loggingRepositories[stream].sendHistoricalLogs(client);
       } else if (stream == kServiceStream) {
         // Send all previously registered service extensions when a client
         // subscribes to the Service stream.
@@ -223,8 +230,13 @@
   );
 
   static const kDebugStream = 'Debug';
+  static const kExtensionStream = 'Extension';
   static const kIsolateStream = 'Isolate';
   static const kLoggingStream = 'Logging';
+  static const kStderrStream = 'Stderr';
+  static const kStdoutStream = 'Stdout';
+
+  static Map<String, _LoggingRepository> loggingRepositories = {};
 
   // Never cancel the Debug or Isolate stream as `_IsolateManager` requires
   // them for isolate state notifications.
@@ -233,10 +245,13 @@
     kIsolateStream,
   };
 
-  // Never cancel the Logging stream as `_LoggingRepository` requires it to
-  // keep a log history.
+  // Never cancel the logging and extension event streams as `_LoggingRepository`
+  // requires them keep history.
   static const loggingRepositoryStreams = <String>{
+    kExtensionStream,
     kLoggingStream,
+    kStderrStream,
+    kStdoutStream,
   };
 
   // The set of streams that DDS requires to function.
diff --git a/pkg/dds/pubspec.yaml b/pkg/dds/pubspec.yaml
index a7ae669..d2fdbdb 100644
--- a/pkg/dds/pubspec.yaml
+++ b/pkg/dds/pubspec.yaml
@@ -3,7 +3,7 @@
   A library used to spawn the Dart Developer Service, used to communicate with
   a Dart VM Service instance.
 
-version: 1.4.1
+version: 1.5.0
 
 homepage: https://github.com/dart-lang/sdk/tree/master/pkg/dds
 
diff --git a/pkg/front_end/lib/src/fasta/fasta_codes_cfe_generated.dart b/pkg/front_end/lib/src/fasta/fasta_codes_cfe_generated.dart
index ecc1198..64581cce 100644
--- a/pkg/front_end/lib/src/fasta/fasta_codes_cfe_generated.dart
+++ b/pkg/front_end/lib/src/fasta/fasta_codes_cfe_generated.dart
@@ -242,6 +242,73 @@
 }
 
 // DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Template<Message Function(DartType _type, bool isNonNullableByDefault)>
+    templateArgumentTypeNotAssignableNullabilityNull = const Template<
+            Message Function(DartType _type, bool isNonNullableByDefault)>(
+        messageTemplate:
+            r"""The value 'null' can't be assigned to the parameter type '#type' because '#type' is not nullable.""",
+        withArguments: _withArgumentsArgumentTypeNotAssignableNullabilityNull);
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Code<Message Function(DartType _type, bool isNonNullableByDefault)>
+    codeArgumentTypeNotAssignableNullabilityNull =
+    const Code<Message Function(DartType _type, bool isNonNullableByDefault)>(
+        "ArgumentTypeNotAssignableNullabilityNull",
+        templateArgumentTypeNotAssignableNullabilityNull,
+        analyzerCodes: <String>["ARGUMENT_TYPE_NOT_ASSIGNABLE"]);
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+Message _withArgumentsArgumentTypeNotAssignableNullabilityNull(
+    DartType _type, bool isNonNullableByDefault) {
+  TypeLabeler labeler = new TypeLabeler(isNonNullableByDefault);
+  List<Object> typeParts = labeler.labelType(_type);
+  String type = typeParts.join();
+  return new Message(codeArgumentTypeNotAssignableNullabilityNull,
+      message:
+          """The value 'null' can't be assigned to the parameter type '${type}' because '${type}' is not nullable.""" +
+              labeler.originMessages,
+      arguments: {'type': _type});
+}
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Template<
+        Message Function(
+            DartType _type, DartType _type2, bool isNonNullableByDefault)>
+    templateArgumentTypeNotAssignableNullabilityNullType = const Template<
+            Message Function(
+                DartType _type, DartType _type2, bool isNonNullableByDefault)>(
+        messageTemplate:
+            r"""The argument type '#type' can't be assigned to the parameter type '#type2' because '#type2' is not nullable.""",
+        withArguments:
+            _withArgumentsArgumentTypeNotAssignableNullabilityNullType);
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Code<
+        Message Function(
+            DartType _type, DartType _type2, bool isNonNullableByDefault)>
+    codeArgumentTypeNotAssignableNullabilityNullType = const Code<
+            Message Function(
+                DartType _type, DartType _type2, bool isNonNullableByDefault)>(
+        "ArgumentTypeNotAssignableNullabilityNullType",
+        templateArgumentTypeNotAssignableNullabilityNullType,
+        analyzerCodes: <String>["ARGUMENT_TYPE_NOT_ASSIGNABLE"]);
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+Message _withArgumentsArgumentTypeNotAssignableNullabilityNullType(
+    DartType _type, DartType _type2, bool isNonNullableByDefault) {
+  TypeLabeler labeler = new TypeLabeler(isNonNullableByDefault);
+  List<Object> typeParts = labeler.labelType(_type);
+  List<Object> type2Parts = labeler.labelType(_type2);
+  String type = typeParts.join();
+  String type2 = type2Parts.join();
+  return new Message(codeArgumentTypeNotAssignableNullabilityNullType,
+      message:
+          """The argument type '${type}' can't be assigned to the parameter type '${type2}' because '${type2}' is not nullable.""" +
+              labeler.originMessages,
+      arguments: {'type': _type, 'type2': _type2});
+}
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
 const Template<
         Message Function(DartType _type, DartType _type2, DartType _type3,
             DartType _type4, bool isNonNullableByDefault)>
@@ -1978,6 +2045,72 @@
 }
 
 // DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Template<Message Function(DartType _type, bool isNonNullableByDefault)>
+    templateInvalidAssignmentErrorNullabilityNull = const Template<
+            Message Function(DartType _type, bool isNonNullableByDefault)>(
+        messageTemplate:
+            r"""The value 'null' can't be assigned to a variable of type '#type' because '#type' is not nullable.""",
+        withArguments: _withArgumentsInvalidAssignmentErrorNullabilityNull);
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Code<Message Function(DartType _type, bool isNonNullableByDefault)>
+    codeInvalidAssignmentErrorNullabilityNull =
+    const Code<Message Function(DartType _type, bool isNonNullableByDefault)>(
+        "InvalidAssignmentErrorNullabilityNull",
+        templateInvalidAssignmentErrorNullabilityNull,
+        analyzerCodes: <String>["INVALID_ASSIGNMENT"]);
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+Message _withArgumentsInvalidAssignmentErrorNullabilityNull(
+    DartType _type, bool isNonNullableByDefault) {
+  TypeLabeler labeler = new TypeLabeler(isNonNullableByDefault);
+  List<Object> typeParts = labeler.labelType(_type);
+  String type = typeParts.join();
+  return new Message(codeInvalidAssignmentErrorNullabilityNull,
+      message:
+          """The value 'null' can't be assigned to a variable of type '${type}' because '${type}' is not nullable.""" +
+              labeler.originMessages,
+      arguments: {'type': _type});
+}
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Template<
+        Message Function(
+            DartType _type, DartType _type2, bool isNonNullableByDefault)>
+    templateInvalidAssignmentErrorNullabilityNullType = const Template<
+            Message Function(
+                DartType _type, DartType _type2, bool isNonNullableByDefault)>(
+        messageTemplate:
+            r"""A value of type '#type' can't be assigned to a variable of type '#type2' because '#type2' is not nullable.""",
+        withArguments: _withArgumentsInvalidAssignmentErrorNullabilityNullType);
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Code<
+        Message Function(
+            DartType _type, DartType _type2, bool isNonNullableByDefault)>
+    codeInvalidAssignmentErrorNullabilityNullType = const Code<
+            Message Function(
+                DartType _type, DartType _type2, bool isNonNullableByDefault)>(
+        "InvalidAssignmentErrorNullabilityNullType",
+        templateInvalidAssignmentErrorNullabilityNullType,
+        analyzerCodes: <String>["INVALID_ASSIGNMENT"]);
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+Message _withArgumentsInvalidAssignmentErrorNullabilityNullType(
+    DartType _type, DartType _type2, bool isNonNullableByDefault) {
+  TypeLabeler labeler = new TypeLabeler(isNonNullableByDefault);
+  List<Object> typeParts = labeler.labelType(_type);
+  List<Object> type2Parts = labeler.labelType(_type2);
+  String type = typeParts.join();
+  String type2 = type2Parts.join();
+  return new Message(codeInvalidAssignmentErrorNullabilityNullType,
+      message:
+          """A value of type '${type}' can't be assigned to a variable of type '${type2}' because '${type2}' is not nullable.""" +
+              labeler.originMessages,
+      arguments: {'type': _type, 'type2': _type2});
+}
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
 const Template<
         Message Function(DartType _type, DartType _type2, DartType _type3,
             DartType _type4, bool isNonNullableByDefault)>
@@ -3168,6 +3301,72 @@
 }
 
 // DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Template<Message Function(DartType _type, bool isNonNullableByDefault)>
+    templateInvalidReturnAsyncNullabilityNull = const Template<
+            Message Function(DartType _type, bool isNonNullableByDefault)>(
+        messageTemplate:
+            r"""The value 'null' can't be returned from an async function with return type '#type' because '#type' is not nullable.""",
+        withArguments: _withArgumentsInvalidReturnAsyncNullabilityNull);
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Code<Message Function(DartType _type, bool isNonNullableByDefault)>
+    codeInvalidReturnAsyncNullabilityNull =
+    const Code<Message Function(DartType _type, bool isNonNullableByDefault)>(
+  "InvalidReturnAsyncNullabilityNull",
+  templateInvalidReturnAsyncNullabilityNull,
+);
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+Message _withArgumentsInvalidReturnAsyncNullabilityNull(
+    DartType _type, bool isNonNullableByDefault) {
+  TypeLabeler labeler = new TypeLabeler(isNonNullableByDefault);
+  List<Object> typeParts = labeler.labelType(_type);
+  String type = typeParts.join();
+  return new Message(codeInvalidReturnAsyncNullabilityNull,
+      message:
+          """The value 'null' can't be returned from an async function with return type '${type}' because '${type}' is not nullable.""" +
+              labeler.originMessages,
+      arguments: {'type': _type});
+}
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Template<
+        Message Function(
+            DartType _type, DartType _type2, bool isNonNullableByDefault)>
+    templateInvalidReturnAsyncNullabilityNullType = const Template<
+            Message Function(
+                DartType _type, DartType _type2, bool isNonNullableByDefault)>(
+        messageTemplate:
+            r"""A value of type '#type' can't be returned from an async function with return type '#type2' because '#type2' is not nullable.""",
+        withArguments: _withArgumentsInvalidReturnAsyncNullabilityNullType);
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Code<
+        Message Function(
+            DartType _type, DartType _type2, bool isNonNullableByDefault)>
+    codeInvalidReturnAsyncNullabilityNullType = const Code<
+        Message Function(
+            DartType _type, DartType _type2, bool isNonNullableByDefault)>(
+  "InvalidReturnAsyncNullabilityNullType",
+  templateInvalidReturnAsyncNullabilityNullType,
+);
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+Message _withArgumentsInvalidReturnAsyncNullabilityNullType(
+    DartType _type, DartType _type2, bool isNonNullableByDefault) {
+  TypeLabeler labeler = new TypeLabeler(isNonNullableByDefault);
+  List<Object> typeParts = labeler.labelType(_type);
+  List<Object> type2Parts = labeler.labelType(_type2);
+  String type = typeParts.join();
+  String type2 = type2Parts.join();
+  return new Message(codeInvalidReturnAsyncNullabilityNullType,
+      message:
+          """A value of type '${type}' can't be returned from an async function with return type '${type2}' because '${type2}' is not nullable.""" +
+              labeler.originMessages,
+      arguments: {'type': _type, 'type2': _type2});
+}
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
 const Template<
         Message Function(DartType _type, DartType _type2, DartType _type3,
             DartType _type4, bool isNonNullableByDefault)>
@@ -3255,6 +3454,72 @@
 }
 
 // DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Template<Message Function(DartType _type, bool isNonNullableByDefault)>
+    templateInvalidReturnNullabilityNull = const Template<
+            Message Function(DartType _type, bool isNonNullableByDefault)>(
+        messageTemplate:
+            r"""The value 'null' can't be returned from a function with return type '#type' because '#type' is not nullable.""",
+        withArguments: _withArgumentsInvalidReturnNullabilityNull);
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Code<Message Function(DartType _type, bool isNonNullableByDefault)>
+    codeInvalidReturnNullabilityNull =
+    const Code<Message Function(DartType _type, bool isNonNullableByDefault)>(
+  "InvalidReturnNullabilityNull",
+  templateInvalidReturnNullabilityNull,
+);
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+Message _withArgumentsInvalidReturnNullabilityNull(
+    DartType _type, bool isNonNullableByDefault) {
+  TypeLabeler labeler = new TypeLabeler(isNonNullableByDefault);
+  List<Object> typeParts = labeler.labelType(_type);
+  String type = typeParts.join();
+  return new Message(codeInvalidReturnNullabilityNull,
+      message:
+          """The value 'null' can't be returned from a function with return type '${type}' because '${type}' is not nullable.""" +
+              labeler.originMessages,
+      arguments: {'type': _type});
+}
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Template<
+        Message Function(
+            DartType _type, DartType _type2, bool isNonNullableByDefault)>
+    templateInvalidReturnNullabilityNullType = const Template<
+            Message Function(
+                DartType _type, DartType _type2, bool isNonNullableByDefault)>(
+        messageTemplate:
+            r"""A value of type '#type' can't be returned from a function with return type '#type2' because '#type2' is not nullable.""",
+        withArguments: _withArgumentsInvalidReturnNullabilityNullType);
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+const Code<
+        Message Function(
+            DartType _type, DartType _type2, bool isNonNullableByDefault)>
+    codeInvalidReturnNullabilityNullType = const Code<
+        Message Function(
+            DartType _type, DartType _type2, bool isNonNullableByDefault)>(
+  "InvalidReturnNullabilityNullType",
+  templateInvalidReturnNullabilityNullType,
+);
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
+Message _withArgumentsInvalidReturnNullabilityNullType(
+    DartType _type, DartType _type2, bool isNonNullableByDefault) {
+  TypeLabeler labeler = new TypeLabeler(isNonNullableByDefault);
+  List<Object> typeParts = labeler.labelType(_type);
+  List<Object> type2Parts = labeler.labelType(_type2);
+  String type = typeParts.join();
+  String type2 = type2Parts.join();
+  return new Message(codeInvalidReturnNullabilityNullType,
+      message:
+          """A value of type '${type}' can't be returned from a function with return type '${type2}' because '${type2}' is not nullable.""" +
+              labeler.originMessages,
+      arguments: {'type': _type, 'type2': _type2});
+}
+
+// DO NOT EDIT. THIS FILE IS GENERATED. SEE TOP OF FILE.
 const Template<
         Message Function(DartType _type, DartType _type2, DartType _type3,
             DartType _type4, bool isNonNullableByDefault)>
diff --git a/pkg/front_end/lib/src/fasta/kernel/body_builder.dart b/pkg/front_end/lib/src/fasta/kernel/body_builder.dart
index a4eebe8..d65d47e 100644
--- a/pkg/front_end/lib/src/fasta/kernel/body_builder.dart
+++ b/pkg/front_end/lib/src/fasta/kernel/body_builder.dart
@@ -507,7 +507,9 @@
   }
 
   Statement popBlock(int count, Token openBrace, Token closeBrace) {
-    return forest.createBlock(offsetForToken(openBrace),
+    return forest.createBlock(
+        offsetForToken(openBrace),
+        offsetForToken(closeBrace),
         const GrowableList<Statement>().pop(stack, count) ?? <Statement>[]);
   }
 
@@ -1015,9 +1017,9 @@
             statements.add(parameter.variable);
           }
           statements.add(body);
-          body = forest.createBlock(charOffset, statements);
+          body = forest.createBlock(charOffset, noLocation, statements);
         }
-        body = forest.createBlock(charOffset, <Statement>[
+        body = forest.createBlock(charOffset, noLocation, <Statement>[
           forest.createExpressionStatement(
               noLocation,
               // This error is added after type inference is done, so we
@@ -3777,7 +3779,7 @@
     if (compileTimeErrors == null) {
       push(NullValue.Block);
     } else {
-      push(forest.createBlock(noLocation, compileTimeErrors));
+      push(forest.createBlock(noLocation, noLocation, compileTimeErrors));
     }
   }
 
@@ -3824,7 +3826,7 @@
 
     if (compileTimeErrors != null) {
       compileTimeErrors.add(result);
-      push(forest.createBlock(noLocation, compileTimeErrors));
+      push(forest.createBlock(noLocation, noLocation, compileTimeErrors));
     } else {
       push(result);
     }
@@ -4919,7 +4921,8 @@
           // This must have been a compile-time error.
           assert(isErroneousNode(variable.initializer));
 
-          push(forest.createBlock(declaration.fileOffset, <Statement>[
+          push(forest
+              .createBlock(declaration.fileOffset, noLocation, <Statement>[
             forest.createExpressionStatement(
                 offsetForToken(token), variable.initializer),
             declaration
@@ -5157,6 +5160,7 @@
         if (forest.isVariablesDeclaration(lvalue)) {
           effects = forest.createBlock(
               noLocation,
+              noLocation,
               // New list because the declarations are not a growable list.
               new List<Statement>.from(
                   forest.variablesDeclarationExtractDeclarations(lvalue)));
@@ -6083,7 +6087,7 @@
     if (member.isNative) {
       push(NullValue.FunctionBody);
     } else {
-      push(forest.createBlock(offsetForToken(token), <Statement>[
+      push(forest.createBlock(offsetForToken(token), noLocation, <Statement>[
         buildProblemStatement(
             fasta.templateExpectedFunctionBody.withArguments(token),
             token.charOffset,
diff --git a/pkg/front_end/lib/src/fasta/kernel/combined_member_signature.dart b/pkg/front_end/lib/src/fasta/kernel/combined_member_signature.dart
index ea003a5..f89b4e8 100644
--- a/pkg/front_end/lib/src/fasta/kernel/combined_member_signature.dart
+++ b/pkg/front_end/lib/src/fasta/kernel/combined_member_signature.dart
@@ -582,18 +582,22 @@
       NamedType namedType = functionType.namedParameters.first;
       VariableDeclaration parameter = function.namedParameters.first;
       namedParameters.add(new VariableDeclaration(parameter.name,
-          type: namedType.type, isCovariant: parameter.isCovariant)
+          type: namedType.type,
+          isRequired: namedType.isRequired,
+          isCovariant: parameter.isCovariant)
         ..isGenericCovariantImpl = parameter.isGenericCovariantImpl);
     } else if (namedParameterCount > 1) {
-      Map<String, DartType> namedTypes = {};
+      Map<String, NamedType> namedTypes = {};
       for (NamedType namedType in functionType.namedParameters) {
-        namedTypes[namedType.name] = namedType.type;
+        namedTypes[namedType.name] = namedType;
       }
       for (int i = 0; i < namedParameterCount; i++) {
         VariableDeclaration parameter = function.namedParameters[i];
-        DartType parameterType = namedTypes[parameter.name];
+        NamedType namedParameterType = namedTypes[parameter.name];
         namedParameters.add(new VariableDeclaration(parameter.name,
-            type: parameterType, isCovariant: parameter.isCovariant)
+            type: namedParameterType.type,
+            isRequired: namedParameterType.isRequired,
+            isCovariant: parameter.isCovariant)
           ..isGenericCovariantImpl = parameter.isGenericCovariantImpl);
       }
     }
diff --git a/pkg/front_end/lib/src/fasta/kernel/constant_evaluator.dart b/pkg/front_end/lib/src/fasta/kernel/constant_evaluator.dart
index 58a0b19..bca4392 100644
--- a/pkg/front_end/lib/src/fasta/kernel/constant_evaluator.dart
+++ b/pkg/front_end/lib/src/fasta/kernel/constant_evaluator.dart
@@ -1770,7 +1770,9 @@
       return unevaluated(
           node,
           new MethodInvocation(extract(receiver), node.name,
-              unevaluatedArguments(arguments, {}, node.arguments.types)));
+              unevaluatedArguments(arguments, {}, node.arguments.types))
+            ..fileOffset = node.fileOffset
+            ..flags = node.flags);
     }
 
     final String op = node.name.text;
diff --git a/pkg/front_end/lib/src/fasta/kernel/forest.dart b/pkg/front_end/lib/src/fasta/kernel/forest.dart
index b683259..273a4e7 100644
--- a/pkg/front_end/lib/src/fasta/kernel/forest.dart
+++ b/pkg/front_end/lib/src/fasta/kernel/forest.dart
@@ -311,7 +311,8 @@
 
   /// Return a representation of a block of [statements] at the given
   /// [fileOffset].
-  Statement createBlock(int fileOffset, List<Statement> statements) {
+  Statement createBlock(
+      int fileOffset, int fileEndOffset, List<Statement> statements) {
     assert(fileOffset != null);
     List<Statement> copy;
     for (int i = 0; i < statements.length; i++) {
@@ -323,7 +324,9 @@
         copy.add(statement);
       }
     }
-    return new Block(copy ?? statements)..fileOffset = fileOffset;
+    return new Block(copy ?? statements)
+      ..fileOffset = fileOffset
+      ..fileEndOffset = fileEndOffset;
   }
 
   /// Return a representation of a break statement.
diff --git a/pkg/front_end/lib/src/fasta/kernel/inference_visitor.dart b/pkg/front_end/lib/src/fasta/kernel/inference_visitor.dart
index 2d14e54..f64bdf2 100644
--- a/pkg/front_end/lib/src/fasta/kernel/inference_visitor.dart
+++ b/pkg/front_end/lib/src/fasta/kernel/inference_visitor.dart
@@ -3742,7 +3742,11 @@
         errorTemplate: templateArgumentTypeNotAssignable,
         nullabilityErrorTemplate: templateArgumentTypeNotAssignableNullability,
         nullabilityPartErrorTemplate:
-            templateArgumentTypeNotAssignablePartNullability);
+            templateArgumentTypeNotAssignablePartNullability,
+        nullabilityNullErrorTemplate:
+            templateArgumentTypeNotAssignableNullabilityNull,
+        nullabilityNullTypeErrorTemplate:
+            templateArgumentTypeNotAssignableNullabilityNullType);
 
     Expression equals = new MethodInvocation(
         left,
diff --git a/pkg/front_end/lib/src/fasta/kernel/transform_collections.dart b/pkg/front_end/lib/src/fasta/kernel/transform_collections.dart
index 2f0811c..0d758a1 100644
--- a/pkg/front_end/lib/src/fasta/kernel/transform_collections.dart
+++ b/pkg/front_end/lib/src/fasta/kernel/transform_collections.dart
@@ -754,7 +754,8 @@
         "No fileOffset on ${argument}.");
     return new MethodInvocation(receiver, new Name('add'),
         new Arguments([argument]), isSet ? setAdd : listAdd)
-      ..fileOffset = argument.fileOffset;
+      ..fileOffset = argument.fileOffset
+      ..isInvariant = true;
   }
 
   Expression _createEqualsNull(Expression expression, {bool notEquals: false}) {
@@ -778,7 +779,8 @@
     assert(fileOffset != TreeNode.noOffset);
     return new MethodInvocation(
         receiver, new Name('[]='), new Arguments([key, value]), mapPut)
-      ..fileOffset = fileOffset;
+      ..fileOffset = fileOffset
+      ..isInvariant = true;
   }
 
   AsExpression _createImplicitAs(
diff --git a/pkg/front_end/lib/src/fasta/kernel/transform_set_literals.dart b/pkg/front_end/lib/src/fasta/kernel/transform_set_literals.dart
index ea13c05..67f0898 100644
--- a/pkg/front_end/lib/src/fasta/kernel/transform_set_literals.dart
+++ b/pkg/front_end/lib/src/fasta/kernel/transform_set_literals.dart
@@ -79,7 +79,8 @@
           new Name("add"),
           new Arguments([entry]),
           addMethod)
-        ..fileOffset = entry.fileOffset;
+        ..fileOffset = entry.fileOffset
+        ..isInvariant = true;
       statements.add(new ExpressionStatement(methodInvocation)
         ..fileOffset = methodInvocation.fileOffset);
     }
diff --git a/pkg/front_end/lib/src/fasta/type_inference/closure_context.dart b/pkg/front_end/lib/src/fasta/type_inference/closure_context.dart
index b646152..4de8315 100644
--- a/pkg/front_end/lib/src/fasta/type_inference/closure_context.dart
+++ b/pkg/front_end/lib/src/fasta/type_inference/closure_context.dart
@@ -202,7 +202,11 @@
               errorTemplate: templateInvalidReturn,
               nullabilityErrorTemplate: templateInvalidReturnNullability,
               nullabilityPartErrorTemplate:
-                  templateInvalidReturnPartNullability);
+                  templateInvalidReturnPartNullability,
+              nullabilityNullErrorTemplate:
+                  templateInvalidReturnNullabilityNull,
+              nullabilityNullTypeErrorTemplate:
+                  templateInvalidReturnNullabilityNullType);
           statement.expression = expression..parent = statement;
         }
       }
@@ -558,7 +562,11 @@
               errorTemplate: templateInvalidReturnAsync,
               nullabilityErrorTemplate: templateInvalidReturnAsyncNullability,
               nullabilityPartErrorTemplate:
-                  templateInvalidReturnAsyncPartNullability)
+                  templateInvalidReturnAsyncPartNullability,
+              nullabilityNullErrorTemplate:
+                  templateInvalidReturnAsyncNullabilityNull,
+              nullabilityNullTypeErrorTemplate:
+                  templateInvalidReturnAsyncNullabilityNullType)
             ..parent = statement;
         }
       }
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 682b6ef..d9c7b80 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
@@ -395,6 +395,9 @@
       Template<Message Function(DartType, DartType, bool)> errorTemplate,
       Template<Message Function(DartType, DartType, bool)>
           nullabilityErrorTemplate,
+      Template<Message Function(DartType, bool)> nullabilityNullErrorTemplate,
+      Template<Message Function(DartType, DartType, bool)>
+          nullabilityNullTypeErrorTemplate,
       Template<Message Function(DartType, DartType, DartType, DartType, bool)>
           nullabilityPartErrorTemplate}) {
     return ensureAssignable(
@@ -403,6 +406,8 @@
         isVoidAllowed: isVoidAllowed,
         errorTemplate: errorTemplate,
         nullabilityErrorTemplate: nullabilityErrorTemplate,
+        nullabilityNullErrorTemplate: nullabilityNullErrorTemplate,
+        nullabilityNullTypeErrorTemplate: nullabilityNullTypeErrorTemplate,
         nullabilityPartErrorTemplate: nullabilityPartErrorTemplate);
   }
 
@@ -433,6 +438,9 @@
       Template<Message Function(DartType, DartType, bool)> errorTemplate,
       Template<Message Function(DartType, DartType, bool)>
           nullabilityErrorTemplate,
+      Template<Message Function(DartType, bool)> nullabilityNullErrorTemplate,
+      Template<Message Function(DartType, DartType, bool)>
+          nullabilityNullTypeErrorTemplate,
       Template<Message Function(DartType, DartType, DartType, DartType, bool)>
           nullabilityPartErrorTemplate}) {
     assert(contextType != null);
@@ -442,7 +450,19 @@
     assert((errorTemplate == null) == (nullabilityErrorTemplate == null) &&
         (nullabilityErrorTemplate == null) ==
             (nullabilityPartErrorTemplate == null));
+    // [nullabilityNullErrorTemplate] and [nullabilityNullTypeErrorTemplate]
+    // should be provided together.
+    assert((nullabilityNullErrorTemplate == null) ==
+        (nullabilityNullTypeErrorTemplate == null));
     errorTemplate ??= templateInvalidAssignmentError;
+    if (nullabilityErrorTemplate == null) {
+      // Use [templateInvalidAssignmentErrorNullabilityNull] only if no
+      // specific [nullabilityErrorTemplate] template was passed.
+      nullabilityNullErrorTemplate ??=
+          templateInvalidAssignmentErrorNullabilityNull;
+    }
+    nullabilityNullTypeErrorTemplate ??= nullabilityErrorTemplate ??
+        templateInvalidAssignmentErrorNullabilityNullType;
     nullabilityErrorTemplate ??= templateInvalidAssignmentErrorNullability;
     nullabilityPartErrorTemplate ??=
         templateInvalidAssignmentErrorPartNullability;
@@ -532,12 +552,34 @@
       case AssignabilityKind.unassignableNullability:
         if (expressionType == assignabilityResult.subtype &&
             contextType == assignabilityResult.supertype) {
-          result = _wrapUnassignableExpression(
-              expression,
-              expressionType,
-              contextType,
-              nullabilityErrorTemplate.withArguments(expressionType,
-                  declaredContextType ?? contextType, isNonNullableByDefault));
+          if (expression is NullLiteral &&
+              nullabilityNullErrorTemplate != null) {
+            result = _wrapUnassignableExpression(
+                expression,
+                expressionType,
+                contextType,
+                nullabilityNullErrorTemplate.withArguments(
+                    declaredContextType ?? contextType,
+                    isNonNullableByDefault));
+          } else if (expressionType is NullType) {
+            result = _wrapUnassignableExpression(
+                expression,
+                expressionType,
+                contextType,
+                nullabilityNullTypeErrorTemplate.withArguments(
+                    expressionType,
+                    declaredContextType ?? contextType,
+                    isNonNullableByDefault));
+          } else {
+            result = _wrapUnassignableExpression(
+                expression,
+                expressionType,
+                contextType,
+                nullabilityErrorTemplate.withArguments(
+                    expressionType,
+                    declaredContextType ?? contextType,
+                    isNonNullableByDefault));
+          }
         } else {
           result = _wrapUnassignableExpression(
               expression,
@@ -2130,7 +2172,11 @@
               nullabilityErrorTemplate:
                   templateArgumentTypeNotAssignableNullability,
               nullabilityPartErrorTemplate:
-                  templateArgumentTypeNotAssignablePartNullability);
+                  templateArgumentTypeNotAssignablePartNullability,
+              nullabilityNullErrorTemplate:
+                  templateArgumentTypeNotAssignableNullabilityNull,
+              nullabilityNullTypeErrorTemplate:
+                  templateArgumentTypeNotAssignableNullabilityNullType);
           if (namedExpression == null) {
             arguments.positional[positionalShift + i] = expression
               ..parent = arguments;
diff --git a/pkg/front_end/messages.status b/pkg/front_end/messages.status
index 329faa1..2fe29ec 100644
--- a/pkg/front_end/messages.status
+++ b/pkg/front_end/messages.status
@@ -450,8 +450,12 @@
 InvalidReturn/analyzerCode: Fail
 InvalidReturnAsync/analyzerCode: Fail
 InvalidReturnAsyncNullability/analyzerCode: Fail
+InvalidReturnAsyncNullabilityNull/analyzerCode: Fail
+InvalidReturnAsyncNullabilityNullType/analyzerCode: Fail
 InvalidReturnAsyncPartNullability/analyzerCode: Fail
 InvalidReturnNullability/analyzerCode: Fail
+InvalidReturnNullabilityNull/analyzerCode: Fail
+InvalidReturnNullabilityNullType/analyzerCode: Fail
 InvalidReturnPartNullability/analyzerCode: Fail
 InvalidSuperInInitializer/example: Fail
 InvalidThisInInitializer/example: Fail
diff --git a/pkg/front_end/messages.yaml b/pkg/front_end/messages.yaml
index dea2312..4e6e901 100644
--- a/pkg/front_end/messages.yaml
+++ b/pkg/front_end/messages.yaml
@@ -3318,6 +3318,27 @@
       method(j);
     }
 
+ArgumentTypeNotAssignableNullabilityNull:
+  template: "The value 'null' can't be assigned to the parameter type '#type' because '#type' is not nullable."
+  analyzerCode: ARGUMENT_TYPE_NOT_ASSIGNABLE
+  configuration: nnbd-strong
+  script: >
+    method(int i) {}
+    main() {
+      method(null);
+    }
+
+ArgumentTypeNotAssignableNullabilityNullType:
+  template: "The argument type '#type' can't be assigned to the parameter type '#type2' because '#type2' is not nullable."
+  analyzerCode: ARGUMENT_TYPE_NOT_ASSIGNABLE
+  configuration: nnbd-strong
+  script: >
+    method(int i) {}
+    main() {
+      Null n;
+      method(n);
+    }
+
 InvalidAssignmentError:
   template: "A value of type '#type' can't be assigned to a variable of type '#type2'."
   analyzerCode: INVALID_ASSIGNMENT
@@ -3349,6 +3370,27 @@
       i = j;
     }
 
+InvalidAssignmentErrorNullabilityNull:
+  template: "The value 'null' can't be assigned to a variable of type '#type' because '#type' is not nullable."
+  analyzerCode: INVALID_ASSIGNMENT
+  configuration: nnbd-strong
+  script: >
+    main() {
+      int i = 0;
+      i = null;
+    }
+
+InvalidAssignmentErrorNullabilityNullType:
+  template: "A value of type '#type' can't be assigned to a variable of type '#type2' because '#type2' is not nullable."
+  analyzerCode: INVALID_ASSIGNMENT
+  configuration: nnbd-strong
+  script: >
+    main() {
+      Null n;
+      int i = 0;
+      i = n;
+    }
+
 PatchClassTypeVariablesMismatch:
   template: "A patch class must have the same number of type variables as its origin class."
 
@@ -3882,6 +3924,16 @@
   configuration: nnbd-strong
   declaration: "List<int> foo(List<int?> list) { return list; }"
 
+InvalidReturnNullabilityNull:
+  template: "The value 'null' can't be returned from a function with return type '#type' because '#type' is not nullable."
+  configuration: nnbd-strong
+  declaration: "int foo() { return null; }"
+
+InvalidReturnNullabilityNullType:
+  template: "A value of type '#type' can't be returned from a function with return type '#type2' because '#type2' is not nullable."
+  configuration: nnbd-strong
+  declaration: "int foo(Null i) { return i; }"
+
 InvalidReturnAsync:
   template: "A value of type '#type' can't be returned from an async function with return type '#type2'."
   configuration: nnbd-strong
@@ -3897,6 +3949,16 @@
   configuration: nnbd-strong
   declaration: "Future<List<int>> foo(List<int?> list) async { return list; }"
 
+InvalidReturnAsyncNullabilityNull:
+  template: "The value 'null' can't be returned from an async function with return type '#type' because '#type' is not nullable."
+  configuration: nnbd-strong
+  declaration: "Future<int> foo() async { return null; }"
+
+InvalidReturnAsyncNullabilityNullType:
+  template: "A value of type '#type' can't be returned from an async function with return type '#type2' because '#type2' is not nullable."
+  configuration: nnbd-strong
+  declaration: "Future<int> foo(Null n) async { return n; }"
+
 ImplicitReturnNull:
   template: "A non-null value must be returned since the return type '#type' doesn't allow null."
   configuration: nnbd-strong
diff --git a/pkg/front_end/test/fasta/types/fasta_legacy_upper_bound_test.dart b/pkg/front_end/test/fasta/types/fasta_legacy_upper_bound_test.dart
index 0f771da..cf9cfa5 100644
--- a/pkg/front_end/test/fasta/types/fasta_legacy_upper_bound_test.dart
+++ b/pkg/front_end/test/fasta/types/fasta_legacy_upper_bound_test.dart
@@ -44,11 +44,11 @@
         await context.options.getUriTranslator(),
         new NoneTarget(new TargetFlags()));
     final DillLoader loader = target.loader;
-    loader.appendLibraries(component);
+    loader.appendLibraries(env.component);
     await target.buildOutlines();
     ClassBuilder objectClass =
         loader.coreLibrary.lookupLocalMember("Object", required: true);
-    hierarchy = new ClassHierarchyBuilder(objectClass, loader, coreTypes);
+    hierarchy = new ClassHierarchyBuilder(objectClass, loader, env.coreTypes);
   }
 
   @override
diff --git a/pkg/front_end/test/fasta/types/kernel_legacy_upper_bound_test.dart b/pkg/front_end/test/fasta/types/kernel_legacy_upper_bound_test.dart
index 152d8d6..0409fcb 100644
--- a/pkg/front_end/test/fasta/types/kernel_legacy_upper_bound_test.dart
+++ b/pkg/front_end/test/fasta/types/kernel_legacy_upper_bound_test.dart
@@ -14,7 +14,7 @@
   @override
   Future<void> parseComponent(String source) {
     super.parseComponent(source);
-    hierarchy = new ClassHierarchy(component, coreTypes);
+    hierarchy = new ClassHierarchy(env.component, env.coreTypes);
     return null;
   }
 
diff --git a/pkg/front_end/test/fasta/types/legacy_upper_bound_helper.dart b/pkg/front_end/test/fasta/types/legacy_upper_bound_helper.dart
index d316988..f55fe0a 100644
--- a/pkg/front_end/test/fasta/types/legacy_upper_bound_helper.dart
+++ b/pkg/front_end/test/fasta/types/legacy_upper_bound_helper.dart
@@ -6,58 +6,49 @@
 
 import "package:expect/expect.dart" show Expect;
 
-import "package:kernel/ast.dart"
-    show Class, Component, DartType, InterfaceType, Library, Nullability;
+import "package:kernel/ast.dart";
 
-import "package:kernel/core_types.dart";
-
-import "package:kernel/library_index.dart" show LibraryIndex;
-
-import 'package:kernel/testing/type_parser_environment.dart'
-    as kernel_type_parser show parseComponent;
+import 'package:kernel/testing/type_parser_environment.dart' as parser;
 
 final Uri libraryUri = Uri.parse("org-dartlang-test:///library.dart");
 
 abstract class LegacyUpperBoundTest {
-  Component component;
-
-  CoreTypes coreTypes;
-
-  LibraryIndex index;
-
-  DartType get objectType => coreTypes.objectLegacyRawType;
-
-  DartType get intType => coreTypes.intLegacyRawType;
-
-  DartType get stringType => coreTypes.intLegacyRawType;
-
-  DartType get doubleType => coreTypes.doubleLegacyRawType;
-
-  DartType get boolType => coreTypes.boolLegacyRawType;
+  parser.Env env;
+  Library coreLibrary;
+  Library testLibrary;
 
   void parseComponent(String source) {
-    component = kernel_type_parser.parseComponent(source, libraryUri);
-    coreTypes = new CoreTypes(component);
-    index = new LibraryIndex.all(component);
-  }
-
-  Class getClass(String name) {
-    return index.getClass("$libraryUri", name);
-  }
-
-  Class getCoreClass(String name) {
-    return index.getClass("dart:core", name);
+    env = new parser.Env(source);
+    assert(
+        env.component.libraries.length == 2,
+        "The test component is expected to have exactly two libraries: "
+        "the core library and the test library.");
+    Library firstLibrary = env.component.libraries.first;
+    Library secondLibrary = env.component.libraries.last;
+    if (firstLibrary.importUri.scheme == "dart" &&
+        firstLibrary.importUri.path == "core") {
+      coreLibrary = firstLibrary;
+      testLibrary = secondLibrary;
+    } else {
+      coreLibrary = secondLibrary;
+      testLibrary = firstLibrary;
+    }
   }
 
   DartType getLegacyLeastUpperBound(
       DartType a, DartType b, Library clientLibrary);
 
-  void checkGetLegacyLeastUpperBound(
-      DartType a, DartType b, Library clientLibrary, DartType expected) {
+  void checkLegacyUpTypes(
+      DartType a, DartType b, DartType expected, Library clientLibrary) {
     DartType actual = getLegacyLeastUpperBound(a, b, clientLibrary);
     Expect.equals(expected, actual);
   }
 
+  void checkLegacyUp(String type1, String type2, String expectedType) {
+    checkLegacyUpTypes(env.parseType(type1), env.parseType(type2),
+        env.parseType(expectedType), testLibrary);
+  }
+
   Future<void> test() {
     return asyncTest(() async {
       await test_getLegacyLeastUpperBound_expansive();
@@ -74,36 +65,19 @@
 class C2<T> extends N<N<C2<N<C2<T*>*>*>*>*>;
 """);
 
-    Class N = getClass("N");
-    Class C1 = getClass("C1");
-    Class C2 = getClass("C2");
-    Library testLib = N.enclosingLibrary;
-
     // The least upper bound of C1<int> and N<C1<String>> is Object since the
     // supertypes are
     //     {C1<int>, N<N<C1<int>>>, Object} for C1<int> and
     //     {N<C1<String>>, Object} for N<C1<String>> and
     // Object is the most specific type in the intersection of the supertypes.
-    checkGetLegacyLeastUpperBound(
-        new InterfaceType(C1, Nullability.legacy, [intType]),
-        new InterfaceType(N, Nullability.legacy, [
-          new InterfaceType(C1, Nullability.legacy, [stringType])
-        ]),
-        testLib,
-        objectType);
+    checkLegacyUp("C1<int*>*", "N<C1<String*>*>*", "Object*");
 
     // The least upper bound of C2<int> and N<C2<String>> is Object since the
     // supertypes are
     //     {C2<int>, N<N<C2<N<C2<int>>>>>, Object} for C2<int> and
     //     {N<C2<String>>, Object} for N<C2<String>> and
     // Object is the most specific type in the intersection of the supertypes.
-    checkGetLegacyLeastUpperBound(
-        new InterfaceType(C2, Nullability.legacy, [intType]),
-        new InterfaceType(N, Nullability.legacy, [
-          new InterfaceType(C2, Nullability.legacy, [stringType])
-        ]),
-        testLib,
-        objectType);
+    checkLegacyUp("C2<int*>*", "N<C2<String*>*>*", "Object*");
   }
 
   Future<void> test_getLegacyLeastUpperBound_generic() async {
@@ -116,39 +90,12 @@
 class F implements D<int*, bool*>;
 """);
 
-    Class a = getClass("A");
-    Class b = getClass("B");
-    Class c = getClass("C");
-    Class d = getClass("D");
-    Class e = getClass("E");
-    Class f = getClass("F");
-    Library testLib = a.enclosingLibrary;
-
-    checkGetLegacyLeastUpperBound(
-        new InterfaceType(d, Nullability.legacy, [intType, doubleType]),
-        new InterfaceType(d, Nullability.legacy, [intType, doubleType]),
-        testLib,
-        new InterfaceType(d, Nullability.legacy, [intType, doubleType]));
-    checkGetLegacyLeastUpperBound(
-        new InterfaceType(d, Nullability.legacy, [intType, doubleType]),
-        new InterfaceType(d, Nullability.legacy, [intType, boolType]),
-        testLib,
-        new InterfaceType(b, Nullability.legacy, [intType]));
-    checkGetLegacyLeastUpperBound(
-        new InterfaceType(d, Nullability.legacy, [intType, doubleType]),
-        new InterfaceType(d, Nullability.legacy, [boolType, doubleType]),
-        testLib,
-        new InterfaceType(c, Nullability.legacy, [doubleType]));
-    checkGetLegacyLeastUpperBound(
-        new InterfaceType(d, Nullability.legacy, [intType, doubleType]),
-        new InterfaceType(d, Nullability.legacy, [boolType, intType]),
-        testLib,
-        coreTypes.legacyRawType(a));
-    checkGetLegacyLeastUpperBound(
-        coreTypes.legacyRawType(e),
-        coreTypes.legacyRawType(f),
-        testLib,
-        new InterfaceType(b, Nullability.legacy, [intType]));
+    checkLegacyUp(
+        "D<int*, double*>*", "D<int*, double*>*", "D<int*, double*>*");
+    checkLegacyUp("D<int*, double*>*", "D<int*, bool*>*", "B<int*>*");
+    checkLegacyUp("D<int*, double*>*", "D<bool*, double*>*", "C<double*>*");
+    checkLegacyUp("D<int*, double*>*", "D<bool*, int*>*", "A*");
+    checkLegacyUp("E*", "F*", "B<int*>*");
   }
 
   Future<void> test_getLegacyLeastUpperBound_nonGeneric() async {
@@ -164,31 +111,13 @@
 class I implements C, D, E;
 """);
 
-    Class a = getClass("A");
-    Class b = getClass("B");
-    Class c = getClass("C");
-    Class d = getClass("D");
-    Class f = getClass("F");
-    Class g = getClass("G");
-    Class h = getClass("H");
-    Class i = getClass("I");
-    Library testLib = a.enclosingLibrary;
-
-    checkGetLegacyLeastUpperBound(coreTypes.legacyRawType(a),
-        coreTypes.legacyRawType(b), testLib, objectType);
-    checkGetLegacyLeastUpperBound(
-        coreTypes.legacyRawType(a), objectType, testLib, objectType);
-    checkGetLegacyLeastUpperBound(
-        objectType, coreTypes.legacyRawType(b), testLib, objectType);
-    checkGetLegacyLeastUpperBound(coreTypes.legacyRawType(c),
-        coreTypes.legacyRawType(d), testLib, coreTypes.legacyRawType(a));
-    checkGetLegacyLeastUpperBound(coreTypes.legacyRawType(c),
-        coreTypes.legacyRawType(a), testLib, coreTypes.legacyRawType(a));
-    checkGetLegacyLeastUpperBound(coreTypes.legacyRawType(a),
-        coreTypes.legacyRawType(d), testLib, coreTypes.legacyRawType(a));
-    checkGetLegacyLeastUpperBound(coreTypes.legacyRawType(f),
-        coreTypes.legacyRawType(g), testLib, coreTypes.legacyRawType(a));
-    checkGetLegacyLeastUpperBound(coreTypes.legacyRawType(h),
-        coreTypes.legacyRawType(i), testLib, coreTypes.legacyRawType(a));
+    checkLegacyUp("A*", "B*", "Object*");
+    checkLegacyUp("A*", "Object*", "Object*");
+    checkLegacyUp("Object*", "B*", "Object*");
+    checkLegacyUp("C*", "D*", "A*");
+    checkLegacyUp("C*", "A*", "A*");
+    checkLegacyUp("A*", "D*", "A*");
+    checkLegacyUp("F*", "G*", "A*");
+    checkLegacyUp("H*", "I*", "A*");
   }
 }
diff --git a/pkg/front_end/test/spell_checking_list_code.txt b/pkg/front_end/test/spell_checking_list_code.txt
index d910513..5fd534d 100644
--- a/pkg/front_end/test/spell_checking_list_code.txt
+++ b/pkg/front_end/test/spell_checking_list_code.txt
@@ -801,6 +801,7 @@
 particularly
 patchup
 path
+patterns
 paulberry
 pay
 payload
diff --git a/pkg/front_end/testcases/expression/set_literal.expression.yaml.expect b/pkg/front_end/testcases/expression/set_literal.expression.yaml.expect
index d4d5c54..e622baa 100644
--- a/pkg/front_end/testcases/expression/set_literal.expression.yaml.expect
+++ b/pkg/front_end/testcases/expression/set_literal.expression.yaml.expect
@@ -3,5 +3,5 @@
 method /* from org-dartlang-debug:synthetic_debug_expression */ debugExpr() → dynamic
   return block {
     final dart.core::Set<dart.core::String*>* #t1 = dart.collection::LinkedHashSet::•<dart.core::String*>();
-    #t1.{dart.core::Set::add}("a");
+    #t1.{dart.core::Set::add}{Invariant}("a");
   } =>#t1;
diff --git a/pkg/front_end/testcases/expression/spread_element.expression.yaml.expect b/pkg/front_end/testcases/expression/spread_element.expression.yaml.expect
index 1a1c5a8..e34676b 100644
--- a/pkg/front_end/testcases/expression/spread_element.expression.yaml.expect
+++ b/pkg/front_end/testcases/expression/spread_element.expression.yaml.expect
@@ -7,7 +7,7 @@
       dart.core::Iterator<dart.core::String*>* :sync-for-iterator = main::listOfStrings.{dart.core::Iterable::iterator};
       for (; :sync-for-iterator.{dart.core::Iterator::moveNext}(); ) {
         final dart.core::String* #t2 = :sync-for-iterator.{dart.core::Iterator::current};
-        #t1.{dart.core::List::add}(#t2);
+        #t1.{dart.core::List::add}{Invariant}(#t2);
       }
     }
   } =>#t1;
diff --git a/pkg/front_end/testcases/general/constants/const_collections.dart.strong.expect b/pkg/front_end/testcases/general/constants/const_collections.dart.strong.expect
index 46a4481..b9b41ea 100644
--- a/pkg/front_end/testcases/general/constants/const_collections.dart.strong.expect
+++ b/pkg/front_end/testcases/general/constants/const_collections.dart.strong.expect
@@ -407,8 +407,8 @@
 static field core::List<core::String*>* barAsVar = block {
   final core::List<core::String*>* #t1 = <core::String*>[];
   for (final core::String* #t2 in #C8)
-    #t1.{core::List::add}(#t2);
-  #t1.{core::List::add}("!");
+    #t1.{core::List::add}{Invariant}(#t2);
+  #t1.{core::List::add}{Invariant}("!");
 } =>#t1;
 static const field core::List<core::String*>* barWithNullSpread = invalid-expression "Null value during constant evaluation.";
 static const field core::List<core::String*>* barWithIntSpread = invalid-expression "pkg/front_end/testcases/general/constants/const_collections.dart:23:51: Error: Unexpected type 'int' of a spread.  Expected 'dynamic' or an Iterable.
@@ -482,7 +482,7 @@
   core::print(#C22);
   core::print( block {
     final core::Set<core::String*>* #t3 = col::LinkedHashSet::•<core::String*>();
-    #t3.{core::Set::add}("hello");
+    #t3.{core::Set::add}{Invariant}("hello");
   } =>#t3);
   core::print(#C26);
 }
diff --git a/pkg/front_end/testcases/general/constants/const_collections.dart.strong.transformed.expect b/pkg/front_end/testcases/general/constants/const_collections.dart.strong.transformed.expect
index 40a8b11..168f850 100644
--- a/pkg/front_end/testcases/general/constants/const_collections.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/general/constants/const_collections.dart.strong.transformed.expect
@@ -410,10 +410,10 @@
     core::Iterator<core::String*>* :sync-for-iterator = (#C8).{core::Iterable::iterator};
     for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
       final core::String* #t2 = :sync-for-iterator.{core::Iterator::current};
-      #t1.{core::List::add}(#t2);
+      #t1.{core::List::add}{Invariant}(#t2);
     }
   }
-  #t1.{core::List::add}("!");
+  #t1.{core::List::add}{Invariant}("!");
 } =>#t1;
 static const field core::List<core::String*>* barWithNullSpread = invalid-expression "Null value during constant evaluation.";
 static const field core::List<core::String*>* barWithIntSpread = invalid-expression "pkg/front_end/testcases/general/constants/const_collections.dart:23:51: Error: Unexpected type 'int' of a spread.  Expected 'dynamic' or an Iterable.
@@ -487,7 +487,7 @@
   core::print(#C22);
   core::print( block {
     final core::Set<core::String*>* #t3 = new col::_CompactLinkedHashSet::•<core::String*>();
-    #t3.{core::Set::add}("hello");
+    #t3.{core::Set::add}{Invariant}("hello");
   } =>#t3);
   core::print(#C26);
 }
diff --git a/pkg/front_end/testcases/general/control_flow_collection.dart.strong.expect b/pkg/front_end/testcases/general/control_flow_collection.dart.strong.expect
index 3044135..dffdbc4 100644
--- a/pkg/front_end/testcases/general/control_flow_collection.dart.strong.expect
+++ b/pkg/front_end/testcases/general/control_flow_collection.dart.strong.expect
@@ -6,63 +6,63 @@
 static method main() → dynamic {
   final core::List<core::int*>* aList = block {
     final core::List<core::int*>* #t1 = <core::int*>[];
-    #t1.{core::List::add}(1);
+    #t1.{core::List::add}{Invariant}(1);
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-      #t1.{core::List::add}(2);
+      #t1.{core::List::add}{Invariant}(2);
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-      #t1.{core::List::add}(3);
+      #t1.{core::List::add}{Invariant}(3);
     else
-      #t1.{core::List::add}(1.{core::int::unary-}());
+      #t1.{core::List::add}{Invariant}(1.{core::int::unary-}());
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
       if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-        #t1.{core::List::add}(4);
+        #t1.{core::List::add}{Invariant}(4);
     for (core::int* i in <core::int*>[5, 6, 7])
-      #t1.{core::List::add}(i);
+      #t1.{core::List::add}{Invariant}(i);
     for (core::int* i in <core::int*>[8, 9, 10])
       if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-        #t1.{core::List::add}(i);
+        #t1.{core::List::add}{Invariant}(i);
     for (core::int* i = 11; i.{core::num::<=}(14); i = i.{core::num::+}(1))
-      #t1.{core::List::add}(i);
+      #t1.{core::List::add}{Invariant}(i);
   } =>#t1;
   final core::Set<core::int*>* aSet = block {
     final core::Set<core::int*>* #t2 = col::LinkedHashSet::•<core::int*>();
-    #t2.{core::Set::add}(1);
+    #t2.{core::Set::add}{Invariant}(1);
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-      #t2.{core::Set::add}(2);
+      #t2.{core::Set::add}{Invariant}(2);
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-      #t2.{core::Set::add}(3);
+      #t2.{core::Set::add}{Invariant}(3);
     else
-      #t2.{core::Set::add}(1.{core::int::unary-}());
+      #t2.{core::Set::add}{Invariant}(1.{core::int::unary-}());
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
       if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-        #t2.{core::Set::add}(4);
+        #t2.{core::Set::add}{Invariant}(4);
     for (core::int* i in <core::int*>[5, 6, 7])
-      #t2.{core::Set::add}(i);
+      #t2.{core::Set::add}{Invariant}(i);
     for (core::int* i in <core::int*>[8, 9, 10])
       if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-        #t2.{core::Set::add}(i);
+        #t2.{core::Set::add}{Invariant}(i);
     for (core::int* i = 11; i.{core::num::<=}(14); i = i.{core::num::+}(1))
-      #t2.{core::Set::add}(i);
+      #t2.{core::Set::add}{Invariant}(i);
   } =>#t2;
   final core::Map<core::int*, core::int*>* aMap = block {
     final core::Map<core::int*, core::int*>* #t3 = <core::int*, core::int*>{};
-    #t3.{core::Map::[]=}(1, 1);
+    #t3.{core::Map::[]=}{Invariant}(1, 1);
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-      #t3.{core::Map::[]=}(2, 2);
+      #t3.{core::Map::[]=}{Invariant}(2, 2);
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-      #t3.{core::Map::[]=}(3, 3);
+      #t3.{core::Map::[]=}{Invariant}(3, 3);
     else
-      #t3.{core::Map::[]=}(1.{core::int::unary-}(), 1.{core::int::unary-}());
+      #t3.{core::Map::[]=}{Invariant}(1.{core::int::unary-}(), 1.{core::int::unary-}());
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
       if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-        #t3.{core::Map::[]=}(4, 4);
+        #t3.{core::Map::[]=}{Invariant}(4, 4);
     for (core::int* i in <core::int*>[5, 6, 7])
-      #t3.{core::Map::[]=}(i, i);
+      #t3.{core::Map::[]=}{Invariant}(i, i);
     for (core::int* i in <core::int*>[8, 9, 10])
       if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-        #t3.{core::Map::[]=}(i, i);
+        #t3.{core::Map::[]=}{Invariant}(i, i);
     for (core::int* i = 11; i.{core::num::<=}(14); i = i.{core::num::+}(1))
-      #t3.{core::Map::[]=}(i, i);
+      #t3.{core::Map::[]=}{Invariant}(i, i);
   } =>#t3;
   core::print(aList);
   core::print(aSet);
diff --git a/pkg/front_end/testcases/general/control_flow_collection.dart.strong.transformed.expect b/pkg/front_end/testcases/general/control_flow_collection.dart.strong.transformed.expect
index 6077536..6041ee9 100644
--- a/pkg/front_end/testcases/general/control_flow_collection.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/general/control_flow_collection.dart.strong.transformed.expect
@@ -6,21 +6,21 @@
 static method main() → dynamic {
   final core::List<core::int*>* aList = block {
     final core::List<core::int*>* #t1 = <core::int*>[];
-    #t1.{core::List::add}(1);
+    #t1.{core::List::add}{Invariant}(1);
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-      #t1.{core::List::add}(2);
+      #t1.{core::List::add}{Invariant}(2);
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-      #t1.{core::List::add}(3);
+      #t1.{core::List::add}{Invariant}(3);
     else
-      #t1.{core::List::add}(1.{core::int::unary-}());
+      #t1.{core::List::add}{Invariant}(1.{core::int::unary-}());
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
       if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-        #t1.{core::List::add}(4);
+        #t1.{core::List::add}{Invariant}(4);
     {
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[5, 6, 7].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         core::int* i = :sync-for-iterator.{core::Iterator::current};
-        #t1.{core::List::add}(i);
+        #t1.{core::List::add}{Invariant}(i);
       }
     }
     {
@@ -28,29 +28,29 @@
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         core::int* i = :sync-for-iterator.{core::Iterator::current};
         if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-          #t1.{core::List::add}(i);
+          #t1.{core::List::add}{Invariant}(i);
       }
     }
     for (core::int* i = 11; i.{core::num::<=}(14); i = i.{core::num::+}(1))
-      #t1.{core::List::add}(i);
+      #t1.{core::List::add}{Invariant}(i);
   } =>#t1;
   final core::Set<core::int*>* aSet = block {
     final core::Set<core::int*>* #t2 = new col::_CompactLinkedHashSet::•<core::int*>();
-    #t2.{core::Set::add}(1);
+    #t2.{core::Set::add}{Invariant}(1);
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-      #t2.{core::Set::add}(2);
+      #t2.{core::Set::add}{Invariant}(2);
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-      #t2.{core::Set::add}(3);
+      #t2.{core::Set::add}{Invariant}(3);
     else
-      #t2.{core::Set::add}(1.{core::int::unary-}());
+      #t2.{core::Set::add}{Invariant}(1.{core::int::unary-}());
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
       if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-        #t2.{core::Set::add}(4);
+        #t2.{core::Set::add}{Invariant}(4);
     {
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[5, 6, 7].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         core::int* i = :sync-for-iterator.{core::Iterator::current};
-        #t2.{core::Set::add}(i);
+        #t2.{core::Set::add}{Invariant}(i);
       }
     }
     {
@@ -58,29 +58,29 @@
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         core::int* i = :sync-for-iterator.{core::Iterator::current};
         if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-          #t2.{core::Set::add}(i);
+          #t2.{core::Set::add}{Invariant}(i);
       }
     }
     for (core::int* i = 11; i.{core::num::<=}(14); i = i.{core::num::+}(1))
-      #t2.{core::Set::add}(i);
+      #t2.{core::Set::add}{Invariant}(i);
   } =>#t2;
   final core::Map<core::int*, core::int*>* aMap = block {
     final core::Map<core::int*, core::int*>* #t3 = <core::int*, core::int*>{};
-    #t3.{core::Map::[]=}(1, 1);
+    #t3.{core::Map::[]=}{Invariant}(1, 1);
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-      #t3.{core::Map::[]=}(2, 2);
+      #t3.{core::Map::[]=}{Invariant}(2, 2);
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-      #t3.{core::Map::[]=}(3, 3);
+      #t3.{core::Map::[]=}{Invariant}(3, 3);
     else
-      #t3.{core::Map::[]=}(1.{core::int::unary-}(), 1.{core::int::unary-}());
+      #t3.{core::Map::[]=}{Invariant}(1.{core::int::unary-}(), 1.{core::int::unary-}());
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
       if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-        #t3.{core::Map::[]=}(4, 4);
+        #t3.{core::Map::[]=}{Invariant}(4, 4);
     {
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[5, 6, 7].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         core::int* i = :sync-for-iterator.{core::Iterator::current};
-        #t3.{core::Map::[]=}(i, i);
+        #t3.{core::Map::[]=}{Invariant}(i, i);
       }
     }
     {
@@ -88,11 +88,11 @@
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         core::int* i = :sync-for-iterator.{core::Iterator::current};
         if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-          #t3.{core::Map::[]=}(i, i);
+          #t3.{core::Map::[]=}{Invariant}(i, i);
       }
     }
     for (core::int* i = 11; i.{core::num::<=}(14); i = i.{core::num::+}(1))
-      #t3.{core::Map::[]=}(i, i);
+      #t3.{core::Map::[]=}{Invariant}(i, i);
   } =>#t3;
   core::print(aList);
   core::print(aSet);
diff --git a/pkg/front_end/testcases/general/control_flow_collection_inference.dart.strong.expect b/pkg/front_end/testcases/general/control_flow_collection_inference.dart.strong.expect
index b84574b..4065ab1 100644
--- a/pkg/front_end/testcases/general/control_flow_collection_inference.dart.strong.expect
+++ b/pkg/front_end/testcases/general/control_flow_collection_inference.dart.strong.expect
@@ -454,195 +454,195 @@
   core::List<core::int*>* list10 = block {
     final core::List<core::int*>* #t1 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t1.{core::List::add}(42);
+      #t1.{core::List::add}{Invariant}(42);
   } =>#t1;
   core::Set<core::int*>* set10 = block {
     final core::Set<core::int*>* #t2 = col::LinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t2.{core::Set::add}(42);
-    #t2.{core::Set::add}(null);
+      #t2.{core::Set::add}{Invariant}(42);
+    #t2.{core::Set::add}{Invariant}(null);
   } =>#t2;
   core::Map<core::String*, core::int*>* map10 = block {
     final core::Map<core::String*, core::int*>* #t3 = <core::String*, core::int*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t3.{core::Map::[]=}("bar", 42);
-    #t3.{core::Map::[]=}("baz", null);
+      #t3.{core::Map::[]=}{Invariant}("bar", 42);
+    #t3.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t3;
   core::List<dynamic>* list11 = block {
     final core::List<dynamic>* #t4 = <dynamic>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t4.{core::List::add}(dynVar);
+      #t4.{core::List::add}{Invariant}(dynVar);
   } =>#t4;
   core::Set<dynamic>* set11 = block {
     final core::Set<dynamic>* #t5 = col::LinkedHashSet::•<dynamic>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t5.{core::Set::add}(dynVar);
-    #t5.{core::Set::add}(null);
+      #t5.{core::Set::add}{Invariant}(dynVar);
+    #t5.{core::Set::add}{Invariant}(null);
   } =>#t5;
   core::Map<core::String*, dynamic>* map11 = block {
     final core::Map<core::String*, dynamic>* #t6 = <core::String*, dynamic>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t6.{core::Map::[]=}("bar", dynVar);
-    #t6.{core::Map::[]=}("baz", null);
+      #t6.{core::Map::[]=}{Invariant}("bar", dynVar);
+    #t6.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t6;
   core::List<core::List<core::int*>*>* list12 = block {
     final core::List<core::List<core::int*>*>* #t7 = <core::List<core::int*>*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t7.{core::List::add}(<core::int*>[42]);
+      #t7.{core::List::add}{Invariant}(<core::int*>[42]);
   } =>#t7;
   core::Set<core::List<core::int*>*>* set12 = block {
     final core::Set<core::List<core::int*>*>* #t8 = col::LinkedHashSet::•<core::List<core::int*>*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t8.{core::Set::add}(<core::int*>[42]);
-    #t8.{core::Set::add}(null);
+      #t8.{core::Set::add}{Invariant}(<core::int*>[42]);
+    #t8.{core::Set::add}{Invariant}(null);
   } =>#t8;
   core::Map<core::String*, core::List<core::int*>*>* map12 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t9 = <core::String*, core::List<core::int*>*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t9.{core::Map::[]=}("bar", <core::int*>[42]);
-    #t9.{core::Map::[]=}("baz", null);
+      #t9.{core::Map::[]=}{Invariant}("bar", <core::int*>[42]);
+    #t9.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t9;
   core::List<core::int*>* list20 = block {
     final core::List<core::int*>* #t10 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::int* #t11 in <core::int*>[42])
-        #t10.{core::List::add}(#t11);
+        #t10.{core::List::add}{Invariant}(#t11);
   } =>#t10;
   core::Set<core::int*>* set20 = block {
     final core::Set<core::int*>* #t12 = col::LinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::int* #t13 in <core::int*>[42])
-        #t12.{core::Set::add}(#t13);
-    #t12.{core::Set::add}(null);
+        #t12.{core::Set::add}{Invariant}(#t13);
+    #t12.{core::Set::add}{Invariant}(null);
   } =>#t12;
   core::Map<core::String*, core::int*>* map20 = block {
     final core::Map<core::String*, core::int*>* #t14 = <core::String*, core::int*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::MapEntry<core::String*, core::int*>* #t15 in <core::String*, core::int*>{"bar": 42}.{core::Map::entries})
-        #t14.{core::Map::[]=}(#t15.{core::MapEntry::key}, #t15.{core::MapEntry::value});
-    #t14.{core::Map::[]=}("baz", null);
+        #t14.{core::Map::[]=}{Invariant}(#t15.{core::MapEntry::key}, #t15.{core::MapEntry::value});
+    #t14.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t14;
   core::List<dynamic>* list21 = block {
     final core::List<dynamic>* #t16 = <dynamic>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final dynamic #t17 in <dynamic>[dynVar])
-        #t16.{core::List::add}(#t17);
+        #t16.{core::List::add}{Invariant}(#t17);
   } =>#t16;
   core::Set<dynamic>* set21 = block {
     final core::Set<dynamic>* #t18 = col::LinkedHashSet::•<dynamic>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final dynamic #t19 in <dynamic>[dynVar])
-        #t18.{core::Set::add}(#t19);
-    #t18.{core::Set::add}(null);
+        #t18.{core::Set::add}{Invariant}(#t19);
+    #t18.{core::Set::add}{Invariant}(null);
   } =>#t18;
   core::Map<core::String*, dynamic>* map21 = block {
     final core::Map<core::String*, dynamic>* #t20 = <core::String*, dynamic>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::MapEntry<core::String*, dynamic>* #t21 in <core::String*, dynamic>{"bar": dynVar}.{core::Map::entries})
-        #t20.{core::Map::[]=}(#t21.{core::MapEntry::key}, #t21.{core::MapEntry::value});
-    #t20.{core::Map::[]=}("baz", null);
+        #t20.{core::Map::[]=}{Invariant}(#t21.{core::MapEntry::key}, #t21.{core::MapEntry::value});
+    #t20.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t20;
   core::List<core::List<core::int*>*>* list22 = block {
     final core::List<core::List<core::int*>*>* #t22 = <core::List<core::int*>*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::List<core::int*>* #t23 in <core::List<core::int*>*>[<core::int*>[42]])
-        #t22.{core::List::add}(#t23);
+        #t22.{core::List::add}{Invariant}(#t23);
   } =>#t22;
   core::Set<core::List<core::int*>*>* set22 = block {
     final core::Set<core::List<core::int*>*>* #t24 = col::LinkedHashSet::•<core::List<core::int*>*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::List<core::int*>* #t25 in <core::List<core::int*>*>[<core::int*>[42]])
-        #t24.{core::Set::add}(#t25);
-    #t24.{core::Set::add}(null);
+        #t24.{core::Set::add}{Invariant}(#t25);
+    #t24.{core::Set::add}{Invariant}(null);
   } =>#t24;
   core::Map<core::String*, core::List<core::int*>*>* map22 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t26 = <core::String*, core::List<core::int*>*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::MapEntry<core::String*, core::List<core::int*>*>* #t27 in <core::String*, core::List<core::int*>*>{"bar": <core::int*>[42]}.{core::Map::entries})
-        #t26.{core::Map::[]=}(#t27.{core::MapEntry::key}, #t27.{core::MapEntry::value});
-    #t26.{core::Map::[]=}("baz", null);
+        #t26.{core::Map::[]=}{Invariant}(#t27.{core::MapEntry::key}, #t27.{core::MapEntry::value});
+    #t26.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t26;
   core::List<core::int*>* list30 = block {
     final core::List<core::int*>* #t28 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::int* #t29 in <core::int*>[42])
-          #t28.{core::List::add}(#t29);
+          #t28.{core::List::add}{Invariant}(#t29);
   } =>#t28;
   core::Set<core::int*>* set30 = block {
     final core::Set<core::int*>* #t30 = col::LinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::int* #t31 in <core::int*>[42])
-          #t30.{core::Set::add}(#t31);
-    #t30.{core::Set::add}(null);
+          #t30.{core::Set::add}{Invariant}(#t31);
+    #t30.{core::Set::add}{Invariant}(null);
   } =>#t30;
   core::Map<core::String*, core::int*>* map30 = block {
     final core::Map<core::String*, core::int*>* #t32 = <core::String*, core::int*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::MapEntry<core::String*, core::int*>* #t33 in <core::String*, core::int*>{"bar": 42}.{core::Map::entries})
-          #t32.{core::Map::[]=}(#t33.{core::MapEntry::key}, #t33.{core::MapEntry::value});
-    #t32.{core::Map::[]=}("baz", null);
+          #t32.{core::Map::[]=}{Invariant}(#t33.{core::MapEntry::key}, #t33.{core::MapEntry::value});
+    #t32.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t32;
   core::List<dynamic>* list31 = block {
     final core::List<dynamic>* #t34 = <dynamic>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final dynamic #t35 in <dynamic>[dynVar])
-          #t34.{core::List::add}(#t35);
+          #t34.{core::List::add}{Invariant}(#t35);
   } =>#t34;
   core::Set<dynamic>* set31 = block {
     final core::Set<dynamic>* #t36 = col::LinkedHashSet::•<dynamic>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final dynamic #t37 in <dynamic>[dynVar])
-          #t36.{core::Set::add}(#t37);
-    #t36.{core::Set::add}(null);
+          #t36.{core::Set::add}{Invariant}(#t37);
+    #t36.{core::Set::add}{Invariant}(null);
   } =>#t36;
   core::Map<core::String*, dynamic>* map31 = block {
     final core::Map<core::String*, dynamic>* #t38 = <core::String*, dynamic>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::MapEntry<core::String*, dynamic>* #t39 in <core::String*, dynamic>{"bar": dynVar}.{core::Map::entries})
-          #t38.{core::Map::[]=}(#t39.{core::MapEntry::key}, #t39.{core::MapEntry::value});
-    #t38.{core::Map::[]=}("baz", null);
+          #t38.{core::Map::[]=}{Invariant}(#t39.{core::MapEntry::key}, #t39.{core::MapEntry::value});
+    #t38.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t38;
   core::List<core::List<core::int*>*>* list33 = block {
     final core::List<core::List<core::int*>*>* #t40 = <core::List<core::int*>*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::List<core::int*>* #t41 in <core::List<core::int*>*>[<core::int*>[42]])
-          #t40.{core::List::add}(#t41);
+          #t40.{core::List::add}{Invariant}(#t41);
   } =>#t40;
   core::Set<core::List<core::int*>*>* set33 = block {
     final core::Set<core::List<core::int*>*>* #t42 = col::LinkedHashSet::•<core::List<core::int*>*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::List<core::int*>* #t43 in <core::List<core::int*>*>[<core::int*>[42]])
-          #t42.{core::Set::add}(#t43);
-    #t42.{core::Set::add}(null);
+          #t42.{core::Set::add}{Invariant}(#t43);
+    #t42.{core::Set::add}{Invariant}(null);
   } =>#t42;
   core::Map<core::String*, core::List<core::int*>*>* map33 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t44 = <core::String*, core::List<core::int*>*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::MapEntry<core::String*, core::List<core::int*>*>* #t45 in <core::String*, core::List<core::int*>*>{"bar": <core::int*>[42]}.{core::Map::entries})
-          #t44.{core::Map::[]=}(#t45.{core::MapEntry::key}, #t45.{core::MapEntry::value});
-    #t44.{core::Map::[]=}("baz", null);
+          #t44.{core::Map::[]=}{Invariant}(#t45.{core::MapEntry::key}, #t45.{core::MapEntry::value});
+    #t44.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t44;
   core::List<core::List<core::int*>*>* list40 = block {
     final core::List<core::List<core::int*>*>* #t46 = <core::List<core::int*>*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::List<core::int*>* #t47 in <core::List<core::int*>*>[<core::int*>[]])
-        #t46.{core::List::add}(#t47);
+        #t46.{core::List::add}{Invariant}(#t47);
   } =>#t46;
   core::Set<core::List<core::int*>*>* set40 = block {
     final core::Set<core::List<core::int*>*>* #t48 = col::LinkedHashSet::•<core::List<core::int*>*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::List<core::int*>* #t49 in <core::List<core::int*>*>[<core::int*>[]])
-        #t48.{core::Set::add}(#t49);
-    #t48.{core::Set::add}(null);
+        #t48.{core::Set::add}{Invariant}(#t49);
+    #t48.{core::Set::add}{Invariant}(null);
   } =>#t48;
   core::Map<core::String*, core::List<core::int*>*>* map40 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:39:34: Error: Both Iterable and Map spread elements encountered in ambiguous literal.
   Map<String, List<int>> map40 = {if (oracle(\"foo\")) ...{\"bar\", []}, \"baz\": null};
@@ -652,62 +652,62 @@
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::List<core::int*>* #t51 in block {
         final core::Set<core::List<core::int*>*>* #t52 = col::LinkedHashSet::•<core::List<core::int*>*>();
-        #t52.{core::Set::add}(<core::int*>[]);
+        #t52.{core::Set::add}{Invariant}(<core::int*>[]);
       } =>#t52)
-        #t50.{core::List::add}(#t51);
+        #t50.{core::List::add}{Invariant}(#t51);
   } =>#t50;
   core::Set<core::List<core::int*>*>* set41 = block {
     final core::Set<core::List<core::int*>*>* #t53 = col::LinkedHashSet::•<core::List<core::int*>*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::List<core::int*>* #t54 in block {
         final core::Set<core::List<core::int*>*>* #t55 = col::LinkedHashSet::•<core::List<core::int*>*>();
-        #t55.{core::Set::add}(<core::int*>[]);
+        #t55.{core::Set::add}{Invariant}(<core::int*>[]);
       } =>#t55)
-        #t53.{core::Set::add}(#t54);
-    #t53.{core::Set::add}(null);
+        #t53.{core::Set::add}{Invariant}(#t54);
+    #t53.{core::Set::add}{Invariant}(null);
   } =>#t53;
   core::List<core::List<core::int*>*>* list42 = block {
     final core::List<core::List<core::int*>*>* #t56 = <core::List<core::int*>*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::List<core::int*>* #t57 in <core::List<core::int*>*>[<core::int*>[]])
-          #t56.{core::List::add}(#t57);
+          #t56.{core::List::add}{Invariant}(#t57);
   } =>#t56;
   core::Set<core::List<core::int*>*>* set42 = block {
     final core::Set<core::List<core::int*>*>* #t58 = col::LinkedHashSet::•<core::List<core::int*>*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::List<core::int*>* #t59 in <core::List<core::int*>*>[<core::int*>[]])
-          #t58.{core::Set::add}(#t59);
-    #t58.{core::Set::add}(null);
+          #t58.{core::Set::add}{Invariant}(#t59);
+    #t58.{core::Set::add}{Invariant}(null);
   } =>#t58;
   core::Map<core::String*, core::List<core::int*>*>* map42 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t60 = <core::String*, core::List<core::int*>*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::MapEntry<core::String*, core::List<core::int*>*>* #t61 in <core::String*, core::List<core::int*>*>{"bar": <core::int*>[]}.{core::Map::entries})
-          #t60.{core::Map::[]=}(#t61.{core::MapEntry::key}, #t61.{core::MapEntry::value});
-    #t60.{core::Map::[]=}("baz", null);
+          #t60.{core::Map::[]=}{Invariant}(#t61.{core::MapEntry::key}, #t61.{core::MapEntry::value});
+    #t60.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t60;
   core::List<core::int*>* list50 = block {
     final core::List<core::int*>* #t62 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::int* #t63 in <core::int*>[])
-        #t62.{core::List::add}(#t63);
+        #t62.{core::List::add}{Invariant}(#t63);
   } =>#t62;
   core::Set<core::int*>* set50 = block {
     final core::Set<core::int*>* #t64 = col::LinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::int* #t65 in <core::int*>[])
-        #t64.{core::Set::add}(#t65);
-    #t64.{core::Set::add}(null);
+        #t64.{core::Set::add}{Invariant}(#t65);
+    #t64.{core::Set::add}{Invariant}(null);
   } =>#t64;
   core::Map<core::String*, core::int*>* map50 = block {
     final core::Map<core::String*, core::int*>* #t66 = <core::String*, core::int*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::MapEntry<core::String*, core::int*>* #t67 in <core::String*, core::int*>{}.{core::Map::entries})
-        #t66.{core::Map::[]=}(#t67.{core::MapEntry::key}, #t67.{core::MapEntry::value});
-    #t66.{core::Map::[]=}("baz", null);
+        #t66.{core::Map::[]=}{Invariant}(#t67.{core::MapEntry::key}, #t67.{core::MapEntry::value});
+    #t66.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t66;
   core::List<core::int*>* list51 = block {
     final core::List<core::int*>* #t68 = <core::int*>[];
@@ -715,7 +715,7 @@
       for (final core::int* #t69 in block {
         final core::Set<core::int*>* #t70 = col::LinkedHashSet::•<core::int*>();
       } =>#t70)
-        #t68.{core::List::add}(#t69);
+        #t68.{core::List::add}{Invariant}(#t69);
   } =>#t68;
   core::Set<core::int*>* set51 = block {
     final core::Set<core::int*>* #t71 = col::LinkedHashSet::•<core::int*>();
@@ -723,231 +723,231 @@
       for (final core::int* #t72 in block {
         final core::Set<core::int*>* #t73 = col::LinkedHashSet::•<core::int*>();
       } =>#t73)
-        #t71.{core::Set::add}(#t72);
-    #t71.{core::Set::add}(null);
+        #t71.{core::Set::add}{Invariant}(#t72);
+    #t71.{core::Set::add}{Invariant}(null);
   } =>#t71;
   core::List<core::int*>* list52 = block {
     final core::List<core::int*>* #t74 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::int* #t75 in <core::int*>[])
-          #t74.{core::List::add}(#t75);
+          #t74.{core::List::add}{Invariant}(#t75);
   } =>#t74;
   core::Set<core::int*>* set52 = block {
     final core::Set<core::int*>* #t76 = col::LinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::int* #t77 in <core::int*>[])
-          #t76.{core::Set::add}(#t77);
-    #t76.{core::Set::add}(null);
+          #t76.{core::Set::add}{Invariant}(#t77);
+    #t76.{core::Set::add}{Invariant}(null);
   } =>#t76;
   core::Map<core::String*, core::int*>* map52 = block {
     final core::Map<core::String*, core::int*>* #t78 = <core::String*, core::int*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::MapEntry<core::String*, core::int*>* #t79 in <core::String*, core::int*>{}.{core::Map::entries})
-          #t78.{core::Map::[]=}(#t79.{core::MapEntry::key}, #t79.{core::MapEntry::value});
-    #t78.{core::Map::[]=}("baz", null);
+          #t78.{core::Map::[]=}{Invariant}(#t79.{core::MapEntry::key}, #t79.{core::MapEntry::value});
+    #t78.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t78;
   core::List<core::List<core::int*>*>* list60 = block {
     final core::List<core::List<core::int*>*>* #t80 = <core::List<core::int*>*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::List<core::int*>* #t81 in <core::List<core::int*>*>[<core::int*>[]])
-        #t80.{core::List::add}(#t81);
+        #t80.{core::List::add}{Invariant}(#t81);
   } =>#t80;
   core::Set<core::List<core::int*>*>* set60 = block {
     final core::Set<core::List<core::int*>*>* #t82 = col::LinkedHashSet::•<core::List<core::int*>*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::List<core::int*>* #t83 in <core::List<core::int*>*>[<core::int*>[]])
-        #t82.{core::Set::add}(#t83);
-    #t82.{core::Set::add}(null);
+        #t82.{core::Set::add}{Invariant}(#t83);
+    #t82.{core::Set::add}{Invariant}(null);
   } =>#t82;
   core::Map<core::String*, core::List<core::int*>*>* map60 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t84 = <core::String*, core::List<core::int*>*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::MapEntry<core::String*, core::List<core::int*>*>* #t85 in <core::String*, core::List<core::int*>*>{"bar": <core::int*>[]}.{core::Map::entries})
-        #t84.{core::Map::[]=}(#t85.{core::MapEntry::key}, #t85.{core::MapEntry::value});
-    #t84.{core::Map::[]=}("baz", null);
+        #t84.{core::Map::[]=}{Invariant}(#t85.{core::MapEntry::key}, #t85.{core::MapEntry::value});
+    #t84.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t84;
   core::List<core::List<core::int*>*>* list61 = block {
     final core::List<core::List<core::int*>*>* #t86 = <core::List<core::int*>*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::List<core::int*>* #t87 in <core::List<core::int*>*>[<core::int*>[]])
-          #t86.{core::List::add}(#t87);
+          #t86.{core::List::add}{Invariant}(#t87);
   } =>#t86;
   core::Set<core::List<core::int*>*>* set61 = block {
     final core::Set<core::List<core::int*>*>* #t88 = col::LinkedHashSet::•<core::List<core::int*>*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::List<core::int*>* #t89 in <core::List<core::int*>*>[<core::int*>[]])
-          #t88.{core::Set::add}(#t89);
-    #t88.{core::Set::add}(null);
+          #t88.{core::Set::add}{Invariant}(#t89);
+    #t88.{core::Set::add}{Invariant}(null);
   } =>#t88;
   core::Map<core::String*, core::List<core::int*>*>* map61 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t90 = <core::String*, core::List<core::int*>*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::MapEntry<core::String*, core::List<core::int*>*>* #t91 in <core::String*, core::List<core::int*>*>{"bar": <core::int*>[]}.{core::Map::entries})
-          #t90.{core::Map::[]=}(#t91.{core::MapEntry::key}, #t91.{core::MapEntry::value});
-    #t90.{core::Map::[]=}("baz", null);
+          #t90.{core::Map::[]=}{Invariant}(#t91.{core::MapEntry::key}, #t91.{core::MapEntry::value});
+    #t90.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t90;
   core::List<core::List<core::int*>*>* list70 = block {
     final core::List<core::List<core::int*>*>* #t92 = <core::List<core::int*>*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t92.{core::List::add}(<core::int*>[]);
+      #t92.{core::List::add}{Invariant}(<core::int*>[]);
   } =>#t92;
   core::Set<core::List<core::int*>*>* set70 = block {
     final core::Set<core::List<core::int*>*>* #t93 = col::LinkedHashSet::•<core::List<core::int*>*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t93.{core::Set::add}(<core::int*>[]);
-    #t93.{core::Set::add}(null);
+      #t93.{core::Set::add}{Invariant}(<core::int*>[]);
+    #t93.{core::Set::add}{Invariant}(null);
   } =>#t93;
   core::List<core::List<core::int*>*>* list71 = block {
     final core::List<core::List<core::int*>*>* #t94 = <core::List<core::int*>*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t94.{core::List::add}(<core::int*>[]);
+        #t94.{core::List::add}{Invariant}(<core::int*>[]);
   } =>#t94;
   core::Set<core::List<core::int*>*>* set71 = block {
     final core::Set<core::List<core::int*>*>* #t95 = col::LinkedHashSet::•<core::List<core::int*>*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t95.{core::Set::add}(<core::int*>[]);
-    #t95.{core::Set::add}(null);
+        #t95.{core::Set::add}{Invariant}(<core::int*>[]);
+    #t95.{core::Set::add}{Invariant}(null);
   } =>#t95;
   core::List<core::num*>* list80 = block {
     final core::List<core::num*>* #t96 = <core::num*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t96.{core::List::add}(42);
+      #t96.{core::List::add}{Invariant}(42);
     else
-      #t96.{core::List::add}(3.14);
+      #t96.{core::List::add}{Invariant}(3.14);
   } =>#t96;
   core::Set<core::num*>* set80 = block {
     final core::Set<core::num*>* #t97 = col::LinkedHashSet::•<core::num*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t97.{core::Set::add}(42);
+      #t97.{core::Set::add}{Invariant}(42);
     else
-      #t97.{core::Set::add}(3.14);
-    #t97.{core::Set::add}(null);
+      #t97.{core::Set::add}{Invariant}(3.14);
+    #t97.{core::Set::add}{Invariant}(null);
   } =>#t97;
   core::Map<core::String*, core::num*>* map80 = block {
     final core::Map<core::String*, core::num*>* #t98 = <core::String*, core::num*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t98.{core::Map::[]=}("bar", 42);
+      #t98.{core::Map::[]=}{Invariant}("bar", 42);
     else
-      #t98.{core::Map::[]=}("bar", 3.14);
-    #t98.{core::Map::[]=}("baz", null);
+      #t98.{core::Map::[]=}{Invariant}("bar", 3.14);
+    #t98.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t98;
   core::List<core::num*>* list81 = block {
     final core::List<core::num*>* #t99 = <core::num*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::num* #t100 in listInt)
-        #t99.{core::List::add}(#t100);
+        #t99.{core::List::add}{Invariant}(#t100);
     else
       for (final core::num* #t101 in listDouble)
-        #t99.{core::List::add}(#t101);
+        #t99.{core::List::add}{Invariant}(#t101);
   } =>#t99;
   core::Set<core::num*>* set81 = block {
     final core::Set<core::num*>* #t102 = col::LinkedHashSet::•<core::num*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::num* #t103 in listInt)
-        #t102.{core::Set::add}(#t103);
+        #t102.{core::Set::add}{Invariant}(#t103);
     else
       for (final core::num* #t104 in listDouble)
-        #t102.{core::Set::add}(#t104);
-    #t102.{core::Set::add}(null);
+        #t102.{core::Set::add}{Invariant}(#t104);
+    #t102.{core::Set::add}{Invariant}(null);
   } =>#t102;
   core::Map<core::String*, core::num*>* map81 = block {
     final core::Map<core::String*, core::num*>* #t105 = <core::String*, core::num*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::MapEntry<core::String*, core::num*>* #t106 in mapToInt.{core::Map::entries})
-        #t105.{core::Map::[]=}(#t106.{core::MapEntry::key}, #t106.{core::MapEntry::value});
+        #t105.{core::Map::[]=}{Invariant}(#t106.{core::MapEntry::key}, #t106.{core::MapEntry::value});
     else
       for (final core::MapEntry<core::String*, core::num*>* #t107 in mapToDouble.{core::Map::entries})
-        #t105.{core::Map::[]=}(#t107.{core::MapEntry::key}, #t107.{core::MapEntry::value});
-    #t105.{core::Map::[]=}("baz", null);
+        #t105.{core::Map::[]=}{Invariant}(#t107.{core::MapEntry::key}, #t107.{core::MapEntry::value});
+    #t105.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t105;
   core::List<dynamic>* list82 = block {
     final core::List<dynamic>* #t108 = <dynamic>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final dynamic #t109 in listInt)
-        #t108.{core::List::add}(#t109);
+        #t108.{core::List::add}{Invariant}(#t109);
     else
       for (final dynamic #t110 in dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*)
-        #t108.{core::List::add}(#t110);
+        #t108.{core::List::add}{Invariant}(#t110);
   } =>#t108;
   core::Set<dynamic>* set82 = block {
     final core::Set<dynamic>* #t111 = col::LinkedHashSet::•<dynamic>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final dynamic #t112 in listInt)
-        #t111.{core::Set::add}(#t112);
+        #t111.{core::Set::add}{Invariant}(#t112);
     else
       for (final dynamic #t113 in dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*)
-        #t111.{core::Set::add}(#t113);
-    #t111.{core::Set::add}(null);
+        #t111.{core::Set::add}{Invariant}(#t113);
+    #t111.{core::Set::add}{Invariant}(null);
   } =>#t111;
   core::Set<dynamic>* map82 = block {
     final core::Set<dynamic>* #t114 = col::LinkedHashSet::•<dynamic>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t114.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:71:38: Error: Unexpected type 'Map<String, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t114.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:71:38: Error: Unexpected type 'Map<String, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   var map82 = {if (oracle(\"foo\")) ...mapToInt else ...dynVar, null};
                                      ^");
     else
       for (final dynamic #t115 in dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*)
-        #t114.{core::Set::add}(#t115);
-    #t114.{core::Set::add}(null);
+        #t114.{core::Set::add}{Invariant}(#t115);
+    #t114.{core::Set::add}{Invariant}(null);
   } =>#t114;
   core::List<core::num*>* list83 = block {
     final core::List<core::num*>* #t116 = <core::num*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t116.{core::List::add}(42);
+      #t116.{core::List::add}{Invariant}(42);
     else
       for (final core::num* #t117 in listDouble)
-        #t116.{core::List::add}(#t117);
+        #t116.{core::List::add}{Invariant}(#t117);
   } =>#t116;
   core::Set<core::num*>* set83 = block {
     final core::Set<core::num*>* #t118 = col::LinkedHashSet::•<core::num*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::num* #t119 in listInt)
-        #t118.{core::Set::add}(#t119);
+        #t118.{core::Set::add}{Invariant}(#t119);
     else
-      #t118.{core::Set::add}(3.14);
-    #t118.{core::Set::add}(null);
+      #t118.{core::Set::add}{Invariant}(3.14);
+    #t118.{core::Set::add}{Invariant}(null);
   } =>#t118;
   core::Map<core::String*, core::num*>* map83 = block {
     final core::Map<core::String*, core::num*>* #t120 = <core::String*, core::num*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::MapEntry<core::String*, core::num*>* #t121 in mapToInt.{core::Map::entries})
-        #t120.{core::Map::[]=}(#t121.{core::MapEntry::key}, #t121.{core::MapEntry::value});
+        #t120.{core::Map::[]=}{Invariant}(#t121.{core::MapEntry::key}, #t121.{core::MapEntry::value});
     else
-      #t120.{core::Map::[]=}("bar", 3.14);
-    #t120.{core::Map::[]=}("baz", null);
+      #t120.{core::Map::[]=}{Invariant}("bar", 3.14);
+    #t120.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t120;
   core::List<core::int*>* list90 = block {
     final core::List<core::int*>* #t122 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t122.{core::List::add}(dynVar as{TypeError,ForDynamic} core::int*);
+      #t122.{core::List::add}{Invariant}(dynVar as{TypeError,ForDynamic} core::int*);
   } =>#t122;
   core::Set<core::int*>* set90 = block {
     final core::Set<core::int*>* #t123 = col::LinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t123.{core::Set::add}(dynVar as{TypeError,ForDynamic} core::int*);
-    #t123.{core::Set::add}(null);
+      #t123.{core::Set::add}{Invariant}(dynVar as{TypeError,ForDynamic} core::int*);
+    #t123.{core::Set::add}{Invariant}(null);
   } =>#t123;
   core::Map<core::String*, core::int*>* map90 = block {
     final core::Map<core::String*, core::int*>* #t124 = <core::String*, core::int*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t124.{core::Map::[]=}("bar", dynVar as{TypeError,ForDynamic} core::int*);
-    #t124.{core::Map::[]=}("baz", null);
+      #t124.{core::Map::[]=}{Invariant}("bar", dynVar as{TypeError,ForDynamic} core::int*);
+    #t124.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t124;
   core::List<core::int*>* list91 = block {
     final core::List<core::int*>* #t125 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final dynamic #t126 in dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*) {
         final core::int* #t127 = #t126 as{TypeError} core::int*;
-        #t125.{core::List::add}(#t127);
+        #t125.{core::List::add}{Invariant}(#t127);
       }
   } =>#t125;
   core::Set<core::int*>* set91 = block {
@@ -955,9 +955,9 @@
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final dynamic #t129 in dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*) {
         final core::int* #t130 = #t129 as{TypeError} core::int*;
-        #t128.{core::Set::add}(#t130);
+        #t128.{core::Set::add}{Invariant}(#t130);
       }
-    #t128.{core::Set::add}(null);
+    #t128.{core::Set::add}{Invariant}(null);
   } =>#t128;
   core::Map<core::String*, core::int*>* map91 = block {
     final core::Map<core::String*, core::int*>* #t131 = <core::String*, core::int*>{};
@@ -965,49 +965,49 @@
       for (final core::MapEntry<dynamic, dynamic>* #t132 in (dynVar as{TypeError,ForDynamic} core::Map<dynamic, dynamic>*).{core::Map::entries}) {
         final core::String* #t133 = #t132.{core::MapEntry::key} as{TypeError} core::String*;
         final core::int* #t134 = #t132.{core::MapEntry::value} as{TypeError} core::int*;
-        #t131.{core::Map::[]=}(#t133, #t134);
+        #t131.{core::Map::[]=}{Invariant}(#t133, #t134);
       }
-    #t131.{core::Map::[]=}("baz", null);
+    #t131.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t131;
   core::List<core::int*>* list100 = block {
     final core::List<core::int*>* #t135 = <core::int*>[];
     if(dynVar as{TypeError,ForDynamic} core::bool*)
-      #t135.{core::List::add}(42);
+      #t135.{core::List::add}{Invariant}(42);
   } =>#t135;
   core::Set<core::int*>* set100 = block {
     final core::Set<core::int*>* #t136 = col::LinkedHashSet::•<core::int*>();
     if(dynVar as{TypeError,ForDynamic} core::bool*)
-      #t136.{core::Set::add}(42);
+      #t136.{core::Set::add}{Invariant}(42);
   } =>#t136;
   core::Map<core::int*, core::int*>* map100 = block {
     final core::Map<core::int*, core::int*>* #t137 = <core::int*, core::int*>{};
     if(dynVar as{TypeError,ForDynamic} core::bool*)
-      #t137.{core::Map::[]=}(42, 42);
+      #t137.{core::Map::[]=}{Invariant}(42, 42);
   } =>#t137;
 }
 static method testIfElementErrors(core::Map<core::int*, core::int*>* map) → dynamic {
   block {
     final core::List<core::int*>* #t138 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t138.{core::List::add}(let final<BottomType> #t139 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:87:28: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+      #t138.{core::List::add}{Invariant}(let final<BottomType> #t139 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:87:28: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int>[if (oracle(\"foo\")) \"bar\"];
                            ^" in "bar" as{TypeError} core::int*);
   } =>#t138;
   block {
     final core::Set<core::int*>* #t140 = col::LinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t140.{core::Set::add}(let final<BottomType> #t141 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:88:28: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+      #t140.{core::Set::add}{Invariant}(let final<BottomType> #t141 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:88:28: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int>{if (oracle(\"foo\")) \"bar\", null};
                            ^" in "bar" as{TypeError} core::int*);
-    #t140.{core::Set::add}(null);
+    #t140.{core::Set::add}{Invariant}(null);
   } =>#t140;
   block {
     final core::Map<core::String*, core::int*>* #t142 = <core::String*, core::int*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t142.{core::Map::[]=}("bar", let final<BottomType> #t143 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:89:43: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+      #t142.{core::Map::[]=}{Invariant}("bar", let final<BottomType> #t143 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:89:43: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <String, int>{if (oracle(\"foo\")) \"bar\": \"bar\", \"baz\": null};
                                           ^" in "bar" as{TypeError} core::int*);
-    #t142.{core::Map::[]=}("baz", null);
+    #t142.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t142;
   block {
     final core::List<core::int*>* #t144 = <core::int*>[];
@@ -1015,7 +1015,7 @@
       for (final core::int* #t145 in <core::int*>[let final<BottomType> #t146 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:90:32: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int>[if (oracle(\"foo\")) ...[\"bar\"]];
                                ^" in "bar" as{TypeError} core::int*])
-        #t144.{core::List::add}(#t145);
+        #t144.{core::List::add}{Invariant}(#t145);
   } =>#t144;
   block {
     final core::Set<core::int*>* #t147 = col::LinkedHashSet::•<core::int*>();
@@ -1023,8 +1023,8 @@
       for (final core::int* #t148 in <core::int*>[let final<BottomType> #t149 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:91:32: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int>{if (oracle(\"foo\")) ...[\"bar\"], null};
                                ^" in "bar" as{TypeError} core::int*])
-        #t147.{core::Set::add}(#t148);
-    #t147.{core::Set::add}(null);
+        #t147.{core::Set::add}{Invariant}(#t148);
+    #t147.{core::Set::add}{Invariant}(null);
   } =>#t147;
   block {
     final core::Map<core::String*, core::int*>* #t150 = <core::String*, core::int*>{};
@@ -1032,13 +1032,13 @@
       for (final core::MapEntry<core::String*, core::int*>* #t151 in <core::String*, core::int*>{"bar": let final<BottomType> #t152 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:92:47: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <String, int>{if (oracle(\"foo\")) ...{\"bar\": \"bar\"}, \"baz\": null};
                                               ^" in "bar" as{TypeError} core::int*}.{core::Map::entries})
-        #t150.{core::Map::[]=}(#t151.{core::MapEntry::key}, #t151.{core::MapEntry::value});
-    #t150.{core::Map::[]=}("baz", null);
+        #t150.{core::Map::[]=}{Invariant}(#t151.{core::MapEntry::key}, #t151.{core::MapEntry::value});
+    #t150.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t150;
   block {
     final core::List<core::int*>* #t153 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t153.{core::List::add}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:93:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t153.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:93:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>[if (oracle(\"foo\")) ...map];
                               ^");
@@ -1046,11 +1046,11 @@
   block {
     final core::Set<core::int*>* #t154 = col::LinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t154.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:94:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t154.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:94:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>{if (oracle(\"foo\")) ...map, null};
                               ^");
-    #t154.{core::Set::add}(null);
+    #t154.{core::Set::add}{Invariant}(null);
   } =>#t154;
   <core::String*, core::int*>{invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:95:39: Error: Unexpected type 'List<String>' of a map spread entry.  Expected 'dynamic' or a Map.
  - 'List' is from 'dart:core'.
@@ -1062,58 +1062,58 @@
   block {
     final core::List<core::String*>* #t155 = <core::String*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t155.{core::List::add}(let final<BottomType> #t156 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:96:31: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+      #t155.{core::List::add}{Invariant}(let final<BottomType> #t156 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:96:31: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   <String>[if (oracle(\"foo\")) 42 else 3.14];
                               ^" in 42 as{TypeError} core::String*);
     else
-      #t155.{core::List::add}(let final<BottomType> #t157 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:96:39: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
+      #t155.{core::List::add}{Invariant}(let final<BottomType> #t157 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:96:39: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
   <String>[if (oracle(\"foo\")) 42 else 3.14];
                                       ^" in 3.14 as{TypeError} core::String*);
   } =>#t155;
   block {
     final core::Set<core::String*>* #t158 = col::LinkedHashSet::•<core::String*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t158.{core::Set::add}(let final<BottomType> #t159 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:97:31: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+      #t158.{core::Set::add}{Invariant}(let final<BottomType> #t159 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:97:31: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   <String>{if (oracle(\"foo\")) 42 else 3.14, null};
                               ^" in 42 as{TypeError} core::String*);
     else
-      #t158.{core::Set::add}(let final<BottomType> #t160 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:97:39: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
+      #t158.{core::Set::add}{Invariant}(let final<BottomType> #t160 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:97:39: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
   <String>{if (oracle(\"foo\")) 42 else 3.14, null};
                                       ^" in 3.14 as{TypeError} core::String*);
-    #t158.{core::Set::add}(null);
+    #t158.{core::Set::add}{Invariant}(null);
   } =>#t158;
   block {
     final core::Map<core::String*, core::String*>* #t161 = <core::String*, core::String*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t161.{core::Map::[]=}("bar", let final<BottomType> #t162 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:98:46: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+      #t161.{core::Map::[]=}{Invariant}("bar", let final<BottomType> #t162 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:98:46: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   <String, String>{if (oracle(\"foo\")) \"bar\": 42 else \"baz\": 3.14, \"baz\": null};
                                              ^" in 42 as{TypeError} core::String*);
     else
-      #t161.{core::Map::[]=}("baz", let final<BottomType> #t163 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:98:61: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
+      #t161.{core::Map::[]=}{Invariant}("baz", let final<BottomType> #t163 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:98:61: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
   <String, String>{if (oracle(\"foo\")) \"bar\": 42 else \"baz\": 3.14, \"baz\": null};
                                                             ^" in 3.14 as{TypeError} core::String*);
-    #t161.{core::Map::[]=}("baz", null);
+    #t161.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t161;
   block {
     final core::List<core::int*>* #t164 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t164.{core::List::add}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:99:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t164.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:99:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>[if (oracle(\"foo\")) ...map else 42];
                               ^");
     else
-      #t164.{core::List::add}(42);
+      #t164.{core::List::add}{Invariant}(42);
   } =>#t164;
   block {
     final core::Set<core::int*>* #t165 = col::LinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t165.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:100:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t165.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:100:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>{if (oracle(\"foo\")) ...map else 42, null};
                               ^");
     else
-      #t165.{core::Set::add}(42);
-    #t165.{core::Set::add}(null);
+      #t165.{core::Set::add}{Invariant}(42);
+    #t165.{core::Set::add}{Invariant}(null);
   } =>#t165;
   <core::String*, core::int*>{invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:101:39: Error: Unexpected type 'List<int>' of a map spread entry.  Expected 'dynamic' or a Map.
  - 'List' is from 'dart:core'.
@@ -1125,9 +1125,9 @@
   block {
     final core::List<core::int*>* #t166 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t166.{core::List::add}(42);
+      #t166.{core::List::add}{Invariant}(42);
     else
-      #t166.{core::List::add}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:102:39: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t166.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:102:39: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>[if (oracle(\"foo\")) 42 else ...map];
                                       ^");
@@ -1135,13 +1135,13 @@
   block {
     final core::Set<core::int*>* #t167 = col::LinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t167.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:103:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t167.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:103:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>{if (oracle(\"foo\")) ...map else 42, null};
                               ^");
     else
-      #t167.{core::Set::add}(42);
-    #t167.{core::Set::add}(null);
+      #t167.{core::Set::add}{Invariant}(42);
+    #t167.{core::Set::add}{Invariant}(null);
   } =>#t167;
   <core::String*, core::int*>{invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:104:54: Error: Unexpected type 'List<int>' of a map spread entry.  Expected 'dynamic' or a Map.
  - 'List' is from 'dart:core'.
@@ -1173,63 +1173,63 @@
     if(let final<BottomType> #t169 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:112:27: Error: A value of type 'int' can't be assigned to a variable of type 'bool'.
   List<int> list20 = [if (42) 42];
                           ^" in 42 as{TypeError} core::bool*)
-      #t168.{core::List::add}(42);
+      #t168.{core::List::add}{Invariant}(42);
   } =>#t168;
   core::Set<core::int*>* set20 = block {
     final core::Set<core::int*>* #t170 = col::LinkedHashSet::•<core::int*>();
     if(let final<BottomType> #t171 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:113:25: Error: A value of type 'int' can't be assigned to a variable of type 'bool'.
   Set<int> set20 = {if (42) 42};
                         ^" in 42 as{TypeError} core::bool*)
-      #t170.{core::Set::add}(42);
+      #t170.{core::Set::add}{Invariant}(42);
   } =>#t170;
   core::Map<core::int*, core::int*>* map30 = block {
     final core::Map<core::int*, core::int*>* #t172 = <core::int*, core::int*>{};
     if(let final<BottomType> #t173 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:114:30: Error: A value of type 'int' can't be assigned to a variable of type 'bool'.
   Map<int, int> map30 = {if (42) 42: 42};
                              ^" in 42 as{TypeError} core::bool*)
-      #t172.{core::Map::[]=}(42, 42);
+      #t172.{core::Map::[]=}{Invariant}(42, 42);
   } =>#t172;
   core::List<core::String*>* list40 = block {
     final core::List<core::String*>* #t174 = <core::String*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t174.{core::List::add}(let final<BottomType> #t175 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:115:53: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
+      #t174.{core::List::add}{Invariant}(let final<BottomType> #t175 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:115:53: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
   List<String> list40 = <String>[if (oracle(\"foo\")) true else 42];
                                                     ^" in true as{TypeError} core::String*);
     else
-      #t174.{core::List::add}(let final<BottomType> #t176 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:115:63: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+      #t174.{core::List::add}{Invariant}(let final<BottomType> #t176 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:115:63: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   List<String> list40 = <String>[if (oracle(\"foo\")) true else 42];
                                                               ^" in 42 as{TypeError} core::String*);
   } =>#t174;
   core::Set<core::String*>* set40 = block {
     final core::Set<core::String*>* #t177 = col::LinkedHashSet::•<core::String*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t177.{core::Set::add}(let final<BottomType> #t178 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:116:51: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
+      #t177.{core::Set::add}{Invariant}(let final<BottomType> #t178 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:116:51: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
   Set<String> set40 = <String>{if (oracle(\"foo\")) true else 42};
                                                   ^" in true as{TypeError} core::String*);
     else
-      #t177.{core::Set::add}(let final<BottomType> #t179 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:116:61: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+      #t177.{core::Set::add}{Invariant}(let final<BottomType> #t179 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:116:61: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   Set<String> set40 = <String>{if (oracle(\"foo\")) true else 42};
                                                             ^" in 42 as{TypeError} core::String*);
   } =>#t177;
   core::Map<core::String*, core::int*>* map40 = block {
     final core::Map<core::String*, core::int*>* #t180 = <core::String*, core::int*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t180.{core::Map::[]=}(let final<BottomType> #t181 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:117:61: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
+      #t180.{core::Map::[]=}{Invariant}(let final<BottomType> #t181 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:117:61: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
   Map<String, int> map40 = <String, int>{if (oracle(\"foo\")) true: 42 else 42: 42};
                                                             ^" in true as{TypeError} core::String*, 42);
     else
-      #t180.{core::Map::[]=}(let final<BottomType> #t182 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:117:75: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+      #t180.{core::Map::[]=}{Invariant}(let final<BottomType> #t182 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:117:75: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   Map<String, int> map40 = <String, int>{if (oracle(\"foo\")) true: 42 else 42: 42};
                                                                           ^" in 42 as{TypeError} core::String*, 42);
   } =>#t180;
   core::Map<core::int*, core::String*>* map41 = block {
     final core::Map<core::int*, core::String*>* #t183 = <core::int*, core::String*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t183.{core::Map::[]=}(42, let final<BottomType> #t184 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:118:65: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
+      #t183.{core::Map::[]=}{Invariant}(42, let final<BottomType> #t184 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:118:65: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
   Map<int, String> map41 = <int, String>{if (oracle(\"foo\")) 42: true else 42: 42};
                                                                 ^" in true as{TypeError} core::String*);
     else
-      #t183.{core::Map::[]=}(42, let final<BottomType> #t185 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:118:79: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+      #t183.{core::Map::[]=}{Invariant}(42, let final<BottomType> #t185 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:118:79: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   Map<int, String> map41 = <int, String>{if (oracle(\"foo\")) 42: true else 42: 42};
                                                                               ^" in 42 as{TypeError} core::String*);
   } =>#t183;
@@ -1238,264 +1238,264 @@
   core::List<core::int*>* list10 = block {
     final core::List<core::int*>* #t186 = <core::int*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t186.{core::List::add}(42);
+      #t186.{core::List::add}{Invariant}(42);
   } =>#t186;
   core::Set<core::int*>* set10 = block {
     final core::Set<core::int*>* #t187 = col::LinkedHashSet::•<core::int*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t187.{core::Set::add}(42);
-    #t187.{core::Set::add}(null);
+      #t187.{core::Set::add}{Invariant}(42);
+    #t187.{core::Set::add}{Invariant}(null);
   } =>#t187;
   core::Map<core::String*, core::int*>* map10 = block {
     final core::Map<core::String*, core::int*>* #t188 = <core::String*, core::int*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t188.{core::Map::[]=}("bar", 42);
-    #t188.{core::Map::[]=}("baz", null);
+      #t188.{core::Map::[]=}{Invariant}("bar", 42);
+    #t188.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t188;
   core::List<dynamic>* list11 = block {
     final core::List<dynamic>* #t189 = <dynamic>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t189.{core::List::add}(dynVar);
+      #t189.{core::List::add}{Invariant}(dynVar);
   } =>#t189;
   core::Set<dynamic>* set11 = block {
     final core::Set<dynamic>* #t190 = col::LinkedHashSet::•<dynamic>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t190.{core::Set::add}(dynVar);
-    #t190.{core::Set::add}(null);
+      #t190.{core::Set::add}{Invariant}(dynVar);
+    #t190.{core::Set::add}{Invariant}(null);
   } =>#t190;
   core::Map<core::String*, dynamic>* map11 = block {
     final core::Map<core::String*, dynamic>* #t191 = <core::String*, dynamic>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t191.{core::Map::[]=}("bar", dynVar);
-    #t191.{core::Map::[]=}("baz", null);
+      #t191.{core::Map::[]=}{Invariant}("bar", dynVar);
+    #t191.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t191;
   core::List<core::List<core::int*>*>* list12 = block {
     final core::List<core::List<core::int*>*>* #t192 = <core::List<core::int*>*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t192.{core::List::add}(<core::int*>[42]);
+      #t192.{core::List::add}{Invariant}(<core::int*>[42]);
   } =>#t192;
   core::Set<core::List<core::int*>*>* set12 = block {
     final core::Set<core::List<core::int*>*>* #t193 = col::LinkedHashSet::•<core::List<core::int*>*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t193.{core::Set::add}(<core::int*>[42]);
-    #t193.{core::Set::add}(null);
+      #t193.{core::Set::add}{Invariant}(<core::int*>[42]);
+    #t193.{core::Set::add}{Invariant}(null);
   } =>#t193;
   core::Map<core::String*, core::List<core::int*>*>* map12 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t194 = <core::String*, core::List<core::int*>*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t194.{core::Map::[]=}("bar", <core::int*>[42]);
-    #t194.{core::Map::[]=}("baz", null);
+      #t194.{core::Map::[]=}{Invariant}("bar", <core::int*>[42]);
+    #t194.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t194;
   core::List<core::int*>* list20 = block {
     final core::List<core::int*>* #t195 = <core::int*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::int* #t196 in <core::int*>[42])
-        #t195.{core::List::add}(#t196);
+        #t195.{core::List::add}{Invariant}(#t196);
   } =>#t195;
   core::Set<core::int*>* set20 = block {
     final core::Set<core::int*>* #t197 = col::LinkedHashSet::•<core::int*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::int* #t198 in <core::int*>[42])
-        #t197.{core::Set::add}(#t198);
-    #t197.{core::Set::add}(null);
+        #t197.{core::Set::add}{Invariant}(#t198);
+    #t197.{core::Set::add}{Invariant}(null);
   } =>#t197;
   core::Map<core::String*, core::int*>* map20 = block {
     final core::Map<core::String*, core::int*>* #t199 = <core::String*, core::int*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::MapEntry<core::String*, core::int*>* #t200 in <core::String*, core::int*>{"bar": 42}.{core::Map::entries})
-        #t199.{core::Map::[]=}(#t200.{core::MapEntry::key}, #t200.{core::MapEntry::value});
-    #t199.{core::Map::[]=}("baz", null);
+        #t199.{core::Map::[]=}{Invariant}(#t200.{core::MapEntry::key}, #t200.{core::MapEntry::value});
+    #t199.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t199;
   core::List<dynamic>* list21 = block {
     final core::List<dynamic>* #t201 = <dynamic>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final dynamic #t202 in <dynamic>[dynVar])
-        #t201.{core::List::add}(#t202);
+        #t201.{core::List::add}{Invariant}(#t202);
   } =>#t201;
   core::Set<dynamic>* set21 = block {
     final core::Set<dynamic>* #t203 = col::LinkedHashSet::•<dynamic>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final dynamic #t204 in <dynamic>[dynVar])
-        #t203.{core::Set::add}(#t204);
-    #t203.{core::Set::add}(null);
+        #t203.{core::Set::add}{Invariant}(#t204);
+    #t203.{core::Set::add}{Invariant}(null);
   } =>#t203;
   core::Map<core::String*, dynamic>* map21 = block {
     final core::Map<core::String*, dynamic>* #t205 = <core::String*, dynamic>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::MapEntry<core::String*, dynamic>* #t206 in <core::String*, dynamic>{"bar": dynVar}.{core::Map::entries})
-        #t205.{core::Map::[]=}(#t206.{core::MapEntry::key}, #t206.{core::MapEntry::value});
-    #t205.{core::Map::[]=}("baz", null);
+        #t205.{core::Map::[]=}{Invariant}(#t206.{core::MapEntry::key}, #t206.{core::MapEntry::value});
+    #t205.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t205;
   core::List<core::List<core::int*>*>* list22 = block {
     final core::List<core::List<core::int*>*>* #t207 = <core::List<core::int*>*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::List<core::int*>* #t208 in <core::List<core::int*>*>[<core::int*>[42]])
-        #t207.{core::List::add}(#t208);
+        #t207.{core::List::add}{Invariant}(#t208);
   } =>#t207;
   core::Set<core::List<core::int*>*>* set22 = block {
     final core::Set<core::List<core::int*>*>* #t209 = col::LinkedHashSet::•<core::List<core::int*>*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::List<core::int*>* #t210 in <core::List<core::int*>*>[<core::int*>[42]])
-        #t209.{core::Set::add}(#t210);
-    #t209.{core::Set::add}(null);
+        #t209.{core::Set::add}{Invariant}(#t210);
+    #t209.{core::Set::add}{Invariant}(null);
   } =>#t209;
   core::Map<core::String*, core::List<core::int*>*>* map22 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t211 = <core::String*, core::List<core::int*>*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::MapEntry<core::String*, core::List<core::int*>*>* #t212 in <core::String*, core::List<core::int*>*>{"bar": <core::int*>[42]}.{core::Map::entries})
-        #t211.{core::Map::[]=}(#t212.{core::MapEntry::key}, #t212.{core::MapEntry::value});
-    #t211.{core::Map::[]=}("baz", null);
+        #t211.{core::Map::[]=}{Invariant}(#t212.{core::MapEntry::key}, #t212.{core::MapEntry::value});
+    #t211.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t211;
   core::List<core::int*>* list30 = block {
     final core::List<core::int*>* #t213 = <core::int*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::int* #t214 in <core::int*>[42])
-          #t213.{core::List::add}(#t214);
+          #t213.{core::List::add}{Invariant}(#t214);
   } =>#t213;
   core::Set<core::int*>* set30 = block {
     final core::Set<core::int*>* #t215 = col::LinkedHashSet::•<core::int*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::int* #t216 in <core::int*>[42])
-          #t215.{core::Set::add}(#t216);
-    #t215.{core::Set::add}(null);
+          #t215.{core::Set::add}{Invariant}(#t216);
+    #t215.{core::Set::add}{Invariant}(null);
   } =>#t215;
   core::Map<core::String*, core::int*>* map30 = block {
     final core::Map<core::String*, core::int*>* #t217 = <core::String*, core::int*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::MapEntry<core::String*, core::int*>* #t218 in <core::String*, core::int*>{"bar": 42}.{core::Map::entries})
-          #t217.{core::Map::[]=}(#t218.{core::MapEntry::key}, #t218.{core::MapEntry::value});
-    #t217.{core::Map::[]=}("baz", null);
+          #t217.{core::Map::[]=}{Invariant}(#t218.{core::MapEntry::key}, #t218.{core::MapEntry::value});
+    #t217.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t217;
   core::List<dynamic>* list31 = block {
     final core::List<dynamic>* #t219 = <dynamic>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final dynamic #t220 in <dynamic>[dynVar])
-          #t219.{core::List::add}(#t220);
+          #t219.{core::List::add}{Invariant}(#t220);
   } =>#t219;
   core::Set<dynamic>* set31 = block {
     final core::Set<dynamic>* #t221 = col::LinkedHashSet::•<dynamic>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final dynamic #t222 in <dynamic>[dynVar])
-          #t221.{core::Set::add}(#t222);
-    #t221.{core::Set::add}(null);
+          #t221.{core::Set::add}{Invariant}(#t222);
+    #t221.{core::Set::add}{Invariant}(null);
   } =>#t221;
   core::Map<core::String*, dynamic>* map31 = block {
     final core::Map<core::String*, dynamic>* #t223 = <core::String*, dynamic>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::MapEntry<core::String*, dynamic>* #t224 in <core::String*, dynamic>{"bar": dynVar}.{core::Map::entries})
-          #t223.{core::Map::[]=}(#t224.{core::MapEntry::key}, #t224.{core::MapEntry::value});
-    #t223.{core::Map::[]=}("baz", null);
+          #t223.{core::Map::[]=}{Invariant}(#t224.{core::MapEntry::key}, #t224.{core::MapEntry::value});
+    #t223.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t223;
   core::List<core::List<core::int*>*>* list33 = block {
     final core::List<core::List<core::int*>*>* #t225 = <core::List<core::int*>*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::List<core::int*>* #t226 in <core::List<core::int*>*>[<core::int*>[42]])
-          #t225.{core::List::add}(#t226);
+          #t225.{core::List::add}{Invariant}(#t226);
   } =>#t225;
   core::Set<core::List<core::int*>*>* set33 = block {
     final core::Set<core::List<core::int*>*>* #t227 = col::LinkedHashSet::•<core::List<core::int*>*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::List<core::int*>* #t228 in <core::List<core::int*>*>[<core::int*>[42]])
-          #t227.{core::Set::add}(#t228);
-    #t227.{core::Set::add}(null);
+          #t227.{core::Set::add}{Invariant}(#t228);
+    #t227.{core::Set::add}{Invariant}(null);
   } =>#t227;
   core::Map<core::String*, core::List<core::int*>*>* map33 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t229 = <core::String*, core::List<core::int*>*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::MapEntry<core::String*, core::List<core::int*>*>* #t230 in <core::String*, core::List<core::int*>*>{"bar": <core::int*>[42]}.{core::Map::entries})
-          #t229.{core::Map::[]=}(#t230.{core::MapEntry::key}, #t230.{core::MapEntry::value});
-    #t229.{core::Map::[]=}("baz", null);
+          #t229.{core::Map::[]=}{Invariant}(#t230.{core::MapEntry::key}, #t230.{core::MapEntry::value});
+    #t229.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t229;
   core::List<core::List<core::int*>*>* list40 = block {
     final core::List<core::List<core::int*>*>* #t231 = <core::List<core::int*>*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::List<core::int*>* #t232 in <core::List<core::int*>*>[<core::int*>[]])
-        #t231.{core::List::add}(#t232);
+        #t231.{core::List::add}{Invariant}(#t232);
   } =>#t231;
   core::Set<core::List<core::int*>*>* set40 = block {
     final core::Set<core::List<core::int*>*>* #t233 = col::LinkedHashSet::•<core::List<core::int*>*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::List<core::int*>* #t234 in <core::List<core::int*>*>[<core::int*>[]])
-        #t233.{core::Set::add}(#t234);
-    #t233.{core::Set::add}(null);
+        #t233.{core::Set::add}{Invariant}(#t234);
+    #t233.{core::Set::add}{Invariant}(null);
   } =>#t233;
   core::Map<core::String*, core::List<core::int*>*>* map40 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t235 = <core::String*, core::List<core::int*>*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::MapEntry<core::String*, core::List<core::int*>*>* #t236 in <core::String*, core::List<core::int*>*>{"bar": <core::int*>[]}.{core::Map::entries})
-        #t235.{core::Map::[]=}(#t236.{core::MapEntry::key}, #t236.{core::MapEntry::value});
-    #t235.{core::Map::[]=}("baz", null);
+        #t235.{core::Map::[]=}{Invariant}(#t236.{core::MapEntry::key}, #t236.{core::MapEntry::value});
+    #t235.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t235;
   core::List<core::List<core::int*>*>* list41 = block {
     final core::List<core::List<core::int*>*>* #t237 = <core::List<core::int*>*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::List<core::int*>* #t238 in block {
         final core::Set<core::List<core::int*>*>* #t239 = col::LinkedHashSet::•<core::List<core::int*>*>();
-        #t239.{core::Set::add}(<core::int*>[]);
+        #t239.{core::Set::add}{Invariant}(<core::int*>[]);
       } =>#t239)
-        #t237.{core::List::add}(#t238);
+        #t237.{core::List::add}{Invariant}(#t238);
   } =>#t237;
   core::Set<core::List<core::int*>*>* set41 = block {
     final core::Set<core::List<core::int*>*>* #t240 = col::LinkedHashSet::•<core::List<core::int*>*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::List<core::int*>* #t241 in block {
         final core::Set<core::List<core::int*>*>* #t242 = col::LinkedHashSet::•<core::List<core::int*>*>();
-        #t242.{core::Set::add}(<core::int*>[]);
+        #t242.{core::Set::add}{Invariant}(<core::int*>[]);
       } =>#t242)
-        #t240.{core::Set::add}(#t241);
-    #t240.{core::Set::add}(null);
+        #t240.{core::Set::add}{Invariant}(#t241);
+    #t240.{core::Set::add}{Invariant}(null);
   } =>#t240;
   core::List<core::List<core::int*>*>* list42 = block {
     final core::List<core::List<core::int*>*>* #t243 = <core::List<core::int*>*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::List<core::int*>* #t244 in <core::List<core::int*>*>[<core::int*>[]])
-          #t243.{core::List::add}(#t244);
+          #t243.{core::List::add}{Invariant}(#t244);
   } =>#t243;
   core::Set<core::List<core::int*>*>* set42 = block {
     final core::Set<core::List<core::int*>*>* #t245 = col::LinkedHashSet::•<core::List<core::int*>*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::List<core::int*>* #t246 in <core::List<core::int*>*>[<core::int*>[]])
-          #t245.{core::Set::add}(#t246);
-    #t245.{core::Set::add}(null);
+          #t245.{core::Set::add}{Invariant}(#t246);
+    #t245.{core::Set::add}{Invariant}(null);
   } =>#t245;
   core::Map<core::String*, core::List<core::int*>*>* map42 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t247 = <core::String*, core::List<core::int*>*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::MapEntry<core::String*, core::List<core::int*>*>* #t248 in <core::String*, core::List<core::int*>*>{"bar": <core::int*>[]}.{core::Map::entries})
-          #t247.{core::Map::[]=}(#t248.{core::MapEntry::key}, #t248.{core::MapEntry::value});
-    #t247.{core::Map::[]=}("baz", null);
+          #t247.{core::Map::[]=}{Invariant}(#t248.{core::MapEntry::key}, #t248.{core::MapEntry::value});
+    #t247.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t247;
   core::List<core::int*>* list50 = block {
     final core::List<core::int*>* #t249 = <core::int*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::int* #t250 in <core::int*>[])
-        #t249.{core::List::add}(#t250);
+        #t249.{core::List::add}{Invariant}(#t250);
   } =>#t249;
   core::Set<core::int*>* set50 = block {
     final core::Set<core::int*>* #t251 = col::LinkedHashSet::•<core::int*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::int* #t252 in <core::int*>[])
-        #t251.{core::Set::add}(#t252);
-    #t251.{core::Set::add}(null);
+        #t251.{core::Set::add}{Invariant}(#t252);
+    #t251.{core::Set::add}{Invariant}(null);
   } =>#t251;
   core::Map<core::String*, core::int*>* map50 = block {
     final core::Map<core::String*, core::int*>* #t253 = <core::String*, core::int*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::MapEntry<core::String*, core::int*>* #t254 in <core::String*, core::int*>{}.{core::Map::entries})
-        #t253.{core::Map::[]=}(#t254.{core::MapEntry::key}, #t254.{core::MapEntry::value});
-    #t253.{core::Map::[]=}("baz", null);
+        #t253.{core::Map::[]=}{Invariant}(#t254.{core::MapEntry::key}, #t254.{core::MapEntry::value});
+    #t253.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t253;
   core::List<core::int*>* list51 = block {
     final core::List<core::int*>* #t255 = <core::int*>[];
@@ -1503,7 +1503,7 @@
       for (final core::int* #t256 in block {
         final core::Set<core::int*>* #t257 = col::LinkedHashSet::•<core::int*>();
       } =>#t257)
-        #t255.{core::List::add}(#t256);
+        #t255.{core::List::add}{Invariant}(#t256);
   } =>#t255;
   core::Set<core::int*>* set51 = block {
     final core::Set<core::int*>* #t258 = col::LinkedHashSet::•<core::int*>();
@@ -1511,246 +1511,246 @@
       for (final core::int* #t259 in block {
         final core::Set<core::int*>* #t260 = col::LinkedHashSet::•<core::int*>();
       } =>#t260)
-        #t258.{core::Set::add}(#t259);
-    #t258.{core::Set::add}(null);
+        #t258.{core::Set::add}{Invariant}(#t259);
+    #t258.{core::Set::add}{Invariant}(null);
   } =>#t258;
   core::List<core::int*>* list52 = block {
     final core::List<core::int*>* #t261 = <core::int*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::int* #t262 in <core::int*>[])
-          #t261.{core::List::add}(#t262);
+          #t261.{core::List::add}{Invariant}(#t262);
   } =>#t261;
   core::Set<core::int*>* set52 = block {
     final core::Set<core::int*>* #t263 = col::LinkedHashSet::•<core::int*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::int* #t264 in <core::int*>[])
-          #t263.{core::Set::add}(#t264);
-    #t263.{core::Set::add}(null);
+          #t263.{core::Set::add}{Invariant}(#t264);
+    #t263.{core::Set::add}{Invariant}(null);
   } =>#t263;
   core::List<core::List<core::int*>*>* list60 = block {
     final core::List<core::List<core::int*>*>* #t265 = <core::List<core::int*>*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::List<core::int*>* #t266 in <core::List<core::int*>*>[<core::int*>[]])
-        #t265.{core::List::add}(#t266);
+        #t265.{core::List::add}{Invariant}(#t266);
   } =>#t265;
   core::Set<core::List<core::int*>*>* set60 = block {
     final core::Set<core::List<core::int*>*>* #t267 = col::LinkedHashSet::•<core::List<core::int*>*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::List<core::int*>* #t268 in <core::List<core::int*>*>[<core::int*>[]])
-        #t267.{core::Set::add}(#t268);
-    #t267.{core::Set::add}(null);
+        #t267.{core::Set::add}{Invariant}(#t268);
+    #t267.{core::Set::add}{Invariant}(null);
   } =>#t267;
   core::Map<core::String*, core::List<core::int*>*>* map60 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t269 = <core::String*, core::List<core::int*>*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::MapEntry<core::String*, core::List<core::int*>*>* #t270 in <core::String*, core::List<core::int*>*>{"bar": <core::int*>[]}.{core::Map::entries})
-        #t269.{core::Map::[]=}(#t270.{core::MapEntry::key}, #t270.{core::MapEntry::value});
-    #t269.{core::Map::[]=}("baz", null);
+        #t269.{core::Map::[]=}{Invariant}(#t270.{core::MapEntry::key}, #t270.{core::MapEntry::value});
+    #t269.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t269;
   core::List<core::List<core::int*>*>* list61 = block {
     final core::List<core::List<core::int*>*>* #t271 = <core::List<core::int*>*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::List<core::int*>* #t272 in <core::List<core::int*>*>[<core::int*>[]])
-          #t271.{core::List::add}(#t272);
+          #t271.{core::List::add}{Invariant}(#t272);
   } =>#t271;
   core::Set<core::List<core::int*>*>* set61 = block {
     final core::Set<core::List<core::int*>*>* #t273 = col::LinkedHashSet::•<core::List<core::int*>*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::List<core::int*>* #t274 in <core::List<core::int*>*>[<core::int*>[]])
-          #t273.{core::Set::add}(#t274);
-    #t273.{core::Set::add}(null);
+          #t273.{core::Set::add}{Invariant}(#t274);
+    #t273.{core::Set::add}{Invariant}(null);
   } =>#t273;
   core::Map<core::String*, core::List<core::int*>*>* map61 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t275 = <core::String*, core::List<core::int*>*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::MapEntry<core::String*, core::List<core::int*>*>* #t276 in <core::String*, core::List<core::int*>*>{"bar": <core::int*>[]}.{core::Map::entries})
-          #t275.{core::Map::[]=}(#t276.{core::MapEntry::key}, #t276.{core::MapEntry::value});
-    #t275.{core::Map::[]=}("baz", null);
+          #t275.{core::Map::[]=}{Invariant}(#t276.{core::MapEntry::key}, #t276.{core::MapEntry::value});
+    #t275.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t275;
   core::List<core::List<core::int*>*>* list70 = block {
     final core::List<core::List<core::int*>*>* #t277 = <core::List<core::int*>*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t277.{core::List::add}(<core::int*>[]);
+      #t277.{core::List::add}{Invariant}(<core::int*>[]);
   } =>#t277;
   core::Set<core::List<core::int*>*>* set70 = block {
     final core::Set<core::List<core::int*>*>* #t278 = col::LinkedHashSet::•<core::List<core::int*>*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t278.{core::Set::add}(<core::int*>[]);
-    #t278.{core::Set::add}(null);
+      #t278.{core::Set::add}{Invariant}(<core::int*>[]);
+    #t278.{core::Set::add}{Invariant}(null);
   } =>#t278;
   core::Map<core::String*, core::List<core::int*>*>* map70 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t279 = <core::String*, core::List<core::int*>*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t279.{core::Map::[]=}("bar", <core::int*>[]);
-    #t279.{core::Map::[]=}("baz", null);
+      #t279.{core::Map::[]=}{Invariant}("bar", <core::int*>[]);
+    #t279.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t279;
   core::List<core::List<core::int*>*>* list71 = block {
     final core::List<core::List<core::int*>*>* #t280 = <core::List<core::int*>*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t280.{core::List::add}(<core::int*>[]);
+        #t280.{core::List::add}{Invariant}(<core::int*>[]);
   } =>#t280;
   core::Set<core::List<core::int*>*>* set71 = block {
     final core::Set<core::List<core::int*>*>* #t281 = col::LinkedHashSet::•<core::List<core::int*>*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t281.{core::Set::add}(<core::int*>[]);
-    #t281.{core::Set::add}(null);
+        #t281.{core::Set::add}{Invariant}(<core::int*>[]);
+    #t281.{core::Set::add}{Invariant}(null);
   } =>#t281;
   core::Map<core::String*, core::List<core::int*>*>* map71 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t282 = <core::String*, core::List<core::int*>*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t282.{core::Map::[]=}("bar", <core::int*>[]);
-    #t282.{core::Map::[]=}("baz", null);
+        #t282.{core::Map::[]=}{Invariant}("bar", <core::int*>[]);
+    #t282.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t282;
   core::List<core::num*>* list80 = block {
     final core::List<core::num*>* #t283 = <core::num*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t283.{core::List::add}(42);
+        #t283.{core::List::add}{Invariant}(42);
       else
-        #t283.{core::List::add}(3.14);
+        #t283.{core::List::add}{Invariant}(3.14);
   } =>#t283;
   core::Set<core::num*>* set80 = block {
     final core::Set<core::num*>* #t284 = col::LinkedHashSet::•<core::num*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t284.{core::Set::add}(42);
+        #t284.{core::Set::add}{Invariant}(42);
       else
-        #t284.{core::Set::add}(3.14);
-    #t284.{core::Set::add}(null);
+        #t284.{core::Set::add}{Invariant}(3.14);
+    #t284.{core::Set::add}{Invariant}(null);
   } =>#t284;
   core::Map<core::String*, core::num*>* map80 = block {
     final core::Map<core::String*, core::num*>* #t285 = <core::String*, core::num*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t285.{core::Map::[]=}("bar", 42);
+        #t285.{core::Map::[]=}{Invariant}("bar", 42);
       else
-        #t285.{core::Map::[]=}("bar", 3.14);
-    #t285.{core::Map::[]=}("baz", null);
+        #t285.{core::Map::[]=}{Invariant}("bar", 3.14);
+    #t285.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t285;
   core::List<core::num*>* list81 = block {
     final core::List<core::num*>* #t286 = <core::num*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::num* #t287 in listInt)
-          #t286.{core::List::add}(#t287);
+          #t286.{core::List::add}{Invariant}(#t287);
       else
         for (final core::num* #t288 in listDouble)
-          #t286.{core::List::add}(#t288);
+          #t286.{core::List::add}{Invariant}(#t288);
   } =>#t286;
   core::Set<core::num*>* set81 = block {
     final core::Set<core::num*>* #t289 = col::LinkedHashSet::•<core::num*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::num* #t290 in listInt)
-          #t289.{core::Set::add}(#t290);
+          #t289.{core::Set::add}{Invariant}(#t290);
       else
         for (final core::num* #t291 in listDouble)
-          #t289.{core::Set::add}(#t291);
-    #t289.{core::Set::add}(null);
+          #t289.{core::Set::add}{Invariant}(#t291);
+    #t289.{core::Set::add}{Invariant}(null);
   } =>#t289;
   core::Map<core::String*, core::num*>* map81 = block {
     final core::Map<core::String*, core::num*>* #t292 = <core::String*, core::num*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::MapEntry<core::String*, core::num*>* #t293 in mapStringInt.{core::Map::entries})
-          #t292.{core::Map::[]=}(#t293.{core::MapEntry::key}, #t293.{core::MapEntry::value});
+          #t292.{core::Map::[]=}{Invariant}(#t293.{core::MapEntry::key}, #t293.{core::MapEntry::value});
       else
         for (final core::MapEntry<core::String*, core::num*>* #t294 in mapStringDouble.{core::Map::entries})
-          #t292.{core::Map::[]=}(#t294.{core::MapEntry::key}, #t294.{core::MapEntry::value});
-    #t292.{core::Map::[]=}("baz", null);
+          #t292.{core::Map::[]=}{Invariant}(#t294.{core::MapEntry::key}, #t294.{core::MapEntry::value});
+    #t292.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t292;
   core::List<dynamic>* list82 = block {
     final core::List<dynamic>* #t295 = <dynamic>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final dynamic #t296 in listInt)
-          #t295.{core::List::add}(#t296);
+          #t295.{core::List::add}{Invariant}(#t296);
       else
         for (final dynamic #t297 in dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*)
-          #t295.{core::List::add}(#t297);
+          #t295.{core::List::add}{Invariant}(#t297);
   } =>#t295;
   core::Set<dynamic>* set82 = block {
     final core::Set<dynamic>* #t298 = col::LinkedHashSet::•<dynamic>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final dynamic #t299 in listInt)
-          #t298.{core::Set::add}(#t299);
+          #t298.{core::Set::add}{Invariant}(#t299);
       else
         for (final dynamic #t300 in dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*)
-          #t298.{core::Set::add}(#t300);
-    #t298.{core::Set::add}(null);
+          #t298.{core::Set::add}{Invariant}(#t300);
+    #t298.{core::Set::add}{Invariant}(null);
   } =>#t298;
   core::Map<dynamic, dynamic>* map82 = block {
     final core::Map<dynamic, dynamic>* #t301 = <dynamic, dynamic>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::MapEntry<dynamic, dynamic>* #t302 in mapStringInt.{core::Map::entries})
-          #t301.{core::Map::[]=}(#t302.{core::MapEntry::key}, #t302.{core::MapEntry::value});
+          #t301.{core::Map::[]=}{Invariant}(#t302.{core::MapEntry::key}, #t302.{core::MapEntry::value});
       else
         for (final core::MapEntry<dynamic, dynamic>* #t303 in (dynVar as{TypeError,ForDynamic} core::Map<dynamic, dynamic>*).{core::Map::entries})
-          #t301.{core::Map::[]=}(#t303.{core::MapEntry::key}, #t303.{core::MapEntry::value});
-    #t301.{core::Map::[]=}("baz", null);
+          #t301.{core::Map::[]=}{Invariant}(#t303.{core::MapEntry::key}, #t303.{core::MapEntry::value});
+    #t301.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t301;
   core::List<core::num*>* list83 = block {
     final core::List<core::num*>* #t304 = <core::num*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t304.{core::List::add}(42);
+        #t304.{core::List::add}{Invariant}(42);
       else
         for (final core::num* #t305 in listDouble)
-          #t304.{core::List::add}(#t305);
+          #t304.{core::List::add}{Invariant}(#t305);
   } =>#t304;
   core::Set<core::num*>* set83 = block {
     final core::Set<core::num*>* #t306 = col::LinkedHashSet::•<core::num*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::num* #t307 in listInt)
-          #t306.{core::Set::add}(#t307);
+          #t306.{core::Set::add}{Invariant}(#t307);
       else
-        #t306.{core::Set::add}(3.14);
-    #t306.{core::Set::add}(null);
+        #t306.{core::Set::add}{Invariant}(3.14);
+    #t306.{core::Set::add}{Invariant}(null);
   } =>#t306;
   core::Map<core::String*, core::num*>* map83 = block {
     final core::Map<core::String*, core::num*>* #t308 = <core::String*, core::num*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::MapEntry<core::String*, core::num*>* #t309 in mapStringInt.{core::Map::entries})
-          #t308.{core::Map::[]=}(#t309.{core::MapEntry::key}, #t309.{core::MapEntry::value});
+          #t308.{core::Map::[]=}{Invariant}(#t309.{core::MapEntry::key}, #t309.{core::MapEntry::value});
       else
-        #t308.{core::Map::[]=}("bar", 3.14);
-    #t308.{core::Map::[]=}("baz", null);
+        #t308.{core::Map::[]=}{Invariant}("bar", 3.14);
+    #t308.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t308;
   core::List<core::int*>* list90 = block {
     final core::List<core::int*>* #t310 = <core::int*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t310.{core::List::add}(dynVar as{TypeError,ForDynamic} core::int*);
+      #t310.{core::List::add}{Invariant}(dynVar as{TypeError,ForDynamic} core::int*);
   } =>#t310;
   core::Set<core::int*>* set90 = block {
     final core::Set<core::int*>* #t311 = col::LinkedHashSet::•<core::int*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t311.{core::Set::add}(dynVar as{TypeError,ForDynamic} core::int*);
-    #t311.{core::Set::add}(null);
+      #t311.{core::Set::add}{Invariant}(dynVar as{TypeError,ForDynamic} core::int*);
+    #t311.{core::Set::add}{Invariant}(null);
   } =>#t311;
   core::Map<core::String*, core::int*>* map90 = block {
     final core::Map<core::String*, core::int*>* #t312 = <core::String*, core::int*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t312.{core::Map::[]=}("bar", dynVar as{TypeError,ForDynamic} core::int*);
-    #t312.{core::Map::[]=}("baz", null);
+      #t312.{core::Map::[]=}{Invariant}("bar", dynVar as{TypeError,ForDynamic} core::int*);
+    #t312.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t312;
   core::List<core::int*>* list91 = block {
     final core::List<core::int*>* #t313 = <core::int*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final dynamic #t314 in dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*) {
         final core::int* #t315 = #t314 as{TypeError} core::int*;
-        #t313.{core::List::add}(#t315);
+        #t313.{core::List::add}{Invariant}(#t315);
       }
   } =>#t313;
   core::Set<core::int*>* set91 = block {
@@ -1758,9 +1758,9 @@
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final dynamic #t317 in dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*) {
         final core::int* #t318 = #t317 as{TypeError} core::int*;
-        #t316.{core::Set::add}(#t318);
+        #t316.{core::Set::add}{Invariant}(#t318);
       }
-    #t316.{core::Set::add}(null);
+    #t316.{core::Set::add}{Invariant}(null);
   } =>#t316;
   core::Map<core::String*, core::int*>* map91 = block {
     final core::Map<core::String*, core::int*>* #t319 = <core::String*, core::int*>{};
@@ -1768,100 +1768,100 @@
       for (final core::MapEntry<dynamic, dynamic>* #t320 in (dynVar as{TypeError,ForDynamic} core::Map<dynamic, dynamic>*).{core::Map::entries}) {
         final core::String* #t321 = #t320.{core::MapEntry::key} as{TypeError} core::String*;
         final core::int* #t322 = #t320.{core::MapEntry::value} as{TypeError} core::int*;
-        #t319.{core::Map::[]=}(#t321, #t322);
+        #t319.{core::Map::[]=}{Invariant}(#t321, #t322);
       }
-    #t319.{core::Map::[]=}("baz", null);
+    #t319.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t319;
   core::List<core::int*>* list100 = block {
     final core::List<core::int*>* #t323 = <core::int*>[];
     for (final core::int* #t324 = index = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; index = index.{core::num::+}(1))
-      #t323.{core::List::add}(42);
+      #t323.{core::List::add}{Invariant}(42);
   } =>#t323;
   core::Set<core::int*>* set100 = block {
     final core::Set<core::int*>* #t325 = col::LinkedHashSet::•<core::int*>();
     for (final core::int* #t326 = index = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; index = index.{core::num::+}(1))
-      #t325.{core::Set::add}(42);
+      #t325.{core::Set::add}{Invariant}(42);
   } =>#t325;
   core::Map<core::String*, core::int*>* map100 = block {
     final core::Map<core::String*, core::int*>* #t327 = <core::String*, core::int*>{};
     for (final core::int* #t328 = index = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; index = index.{core::num::+}(1))
-      #t327.{core::Map::[]=}("bar", 42);
+      #t327.{core::Map::[]=}{Invariant}("bar", 42);
   } =>#t327;
   core::List<core::int*>* list110 = block {
     final core::List<core::int*>* #t329 = <core::int*>[];
     for (core::int* i in <core::int*>[1, 2, 3])
-      #t329.{core::List::add}(i);
+      #t329.{core::List::add}{Invariant}(i);
   } =>#t329;
   core::Set<core::int*>* set110 = block {
     final core::Set<core::int*>* #t330 = col::LinkedHashSet::•<core::int*>();
     for (core::int* i in <core::int*>[1, 2, 3])
-      #t330.{core::Set::add}(i);
-    #t330.{core::Set::add}(null);
+      #t330.{core::Set::add}{Invariant}(i);
+    #t330.{core::Set::add}{Invariant}(null);
   } =>#t330;
   core::Map<core::String*, core::int*>* map110 = block {
     final core::Map<core::String*, core::int*>* #t331 = <core::String*, core::int*>{};
     for (core::int* i in <core::int*>[1, 2, 3])
-      #t331.{core::Map::[]=}("bar", i);
-    #t331.{core::Map::[]=}("baz", null);
+      #t331.{core::Map::[]=}{Invariant}("bar", i);
+    #t331.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t331;
   core::List<core::int*>* list120 = block {
     final core::List<core::int*>* #t332 = <core::int*>[];
     for (dynamic i in dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*)
-      #t332.{core::List::add}(i as{TypeError,ForDynamic} core::int*);
+      #t332.{core::List::add}{Invariant}(i as{TypeError,ForDynamic} core::int*);
   } =>#t332;
   core::Set<core::int*>* set120 = block {
     final core::Set<core::int*>* #t333 = col::LinkedHashSet::•<core::int*>();
     for (dynamic i in dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*)
-      #t333.{core::Set::add}(i as{TypeError,ForDynamic} core::int*);
-    #t333.{core::Set::add}(null);
+      #t333.{core::Set::add}{Invariant}(i as{TypeError,ForDynamic} core::int*);
+    #t333.{core::Set::add}{Invariant}(null);
   } =>#t333;
   core::Map<core::String*, core::int*>* map120 = block {
     final core::Map<core::String*, core::int*>* #t334 = <core::String*, core::int*>{};
     for (dynamic i in dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*)
-      #t334.{core::Map::[]=}("bar", i as{TypeError,ForDynamic} core::int*);
-    #t334.{core::Map::[]=}("baz", null);
+      #t334.{core::Map::[]=}{Invariant}("bar", i as{TypeError,ForDynamic} core::int*);
+    #t334.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t334;
   core::List<core::int*>* list130 = block {
     final core::List<core::int*>* #t335 = <core::int*>[];
     for (core::int* i = 1; i.{core::num::<}(2); i = i.{core::num::+}(1))
-      #t335.{core::List::add}(i);
+      #t335.{core::List::add}{Invariant}(i);
   } =>#t335;
   core::Set<core::int*>* set130 = block {
     final core::Set<core::int*>* #t336 = col::LinkedHashSet::•<core::int*>();
     for (core::int* i = 1; i.{core::num::<}(2); i = i.{core::num::+}(1))
-      #t336.{core::Set::add}(i);
+      #t336.{core::Set::add}{Invariant}(i);
   } =>#t336;
   core::Map<core::int*, core::int*>* map130 = block {
     final core::Map<core::int*, core::int*>* #t337 = <core::int*, core::int*>{};
     for (core::int* i = 1; i.{core::num::<}(2); i = i.{core::num::+}(1))
-      #t337.{core::Map::[]=}(i, i);
+      #t337.{core::Map::[]=}{Invariant}(i, i);
   } =>#t337;
 }
 static method testForElementErrors(core::Map<core::int*, core::int*>* map, core::List<core::int*>* list) → dynamic async {
   block {
     final core::List<core::int*>* #t338 = <core::int*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t338.{core::List::add}(let final<BottomType> #t339 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:210:45: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+      #t338.{core::List::add}{Invariant}(let final<BottomType> #t339 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:210:45: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int>[for (int i = 0; oracle(\"foo\"); i++) \"bar\"];
                                             ^" in "bar" as{TypeError} core::int*);
   } =>#t338;
   block {
     final core::Set<core::int*>* #t340 = col::LinkedHashSet::•<core::int*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t340.{core::Set::add}(let final<BottomType> #t341 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:211:45: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+      #t340.{core::Set::add}{Invariant}(let final<BottomType> #t341 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:211:45: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int>{for (int i = 0; oracle(\"foo\"); i++) \"bar\", null};
                                             ^" in "bar" as{TypeError} core::int*);
-    #t340.{core::Set::add}(null);
+    #t340.{core::Set::add}{Invariant}(null);
   } =>#t340;
   block {
     final core::Map<core::int*, core::int*>* #t342 = <core::int*, core::int*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t342.{core::Map::[]=}(let final<BottomType> #t343 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:212:50: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+      #t342.{core::Map::[]=}{Invariant}(let final<BottomType> #t343 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:212:50: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int, int>{for (int i = 0; oracle(\"foo\"); i++) \"bar\": \"bar\", \"baz\": null};
                                                  ^" in "bar" as{TypeError} core::int*, let final<BottomType> #t344 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:212:57: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int, int>{for (int i = 0; oracle(\"foo\"); i++) \"bar\": \"bar\", \"baz\": null};
                                                         ^" in "bar" as{TypeError} core::int*);
-    #t342.{core::Map::[]=}(let final<BottomType> #t345 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:212:64: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+    #t342.{core::Map::[]=}{Invariant}(let final<BottomType> #t345 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:212:64: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int, int>{for (int i = 0; oracle(\"foo\"); i++) \"bar\": \"bar\", \"baz\": null};
                                                                ^" in "baz" as{TypeError} core::int*, null);
   } =>#t342;
@@ -1871,7 +1871,7 @@
       for (final core::int* #t347 in <core::int*>[let final<BottomType> #t348 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:213:49: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int>[for (int i = 0; oracle(\"foo\"); i++) ...[\"bar\"]];
                                                 ^" in "bar" as{TypeError} core::int*])
-        #t346.{core::List::add}(#t347);
+        #t346.{core::List::add}{Invariant}(#t347);
   } =>#t346;
   block {
     final core::Set<core::int*>* #t349 = col::LinkedHashSet::•<core::int*>();
@@ -1879,8 +1879,8 @@
       for (final core::int* #t350 in <core::int*>[let final<BottomType> #t351 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:214:49: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int>{for (int i = 0; oracle(\"foo\"); i++) ...[\"bar\"], null};
                                                 ^" in "bar" as{TypeError} core::int*])
-        #t349.{core::Set::add}(#t350);
-    #t349.{core::Set::add}(null);
+        #t349.{core::Set::add}{Invariant}(#t350);
+    #t349.{core::Set::add}{Invariant}(null);
   } =>#t349;
   block {
     final core::Map<core::int*, core::int*>* #t352 = <core::int*, core::int*>{};
@@ -1890,15 +1890,15 @@
                                                      ^" in "bar" as{TypeError} core::int*: let final<BottomType> #t355 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:215:61: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int, int>{for (int i = 0; oracle(\"foo\"); i++) ...{\"bar\": \"bar\"}, \"baz\": null};
                                                             ^" in "bar" as{TypeError} core::int*}.{core::Map::entries})
-        #t352.{core::Map::[]=}(#t353.{core::MapEntry::key}, #t353.{core::MapEntry::value});
-    #t352.{core::Map::[]=}(let final<BottomType> #t356 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:215:69: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+        #t352.{core::Map::[]=}{Invariant}(#t353.{core::MapEntry::key}, #t353.{core::MapEntry::value});
+    #t352.{core::Map::[]=}{Invariant}(let final<BottomType> #t356 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:215:69: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int, int>{for (int i = 0; oracle(\"foo\"); i++) ...{\"bar\": \"bar\"}, \"baz\": null};
                                                                     ^" in "baz" as{TypeError} core::int*, null);
   } =>#t352;
   block {
     final core::List<core::int*>* #t357 = <core::int*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t357.{core::List::add}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:216:48: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t357.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:216:48: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>[for (int i = 0; oracle(\"foo\"); i++) ...map];
                                                ^");
@@ -1906,11 +1906,11 @@
   block {
     final core::Set<core::int*>* #t358 = col::LinkedHashSet::•<core::int*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t358.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:217:48: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t358.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:217:48: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>{for (int i = 0; oracle(\"foo\"); i++) ...map, null};
                                                ^");
-    #t358.{core::Set::add}(null);
+    #t358.{core::Set::add}{Invariant}(null);
   } =>#t358;
   <core::int*, core::int*>{invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:218:53: Error: Unexpected type 'List<int>' of a map spread entry.  Expected 'dynamic' or a Map.
  - 'List' is from 'dart:core'.
@@ -1923,11 +1923,11 @@
     final core::List<core::String*>* #t359 = <core::String*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t359.{core::List::add}(let final<BottomType> #t360 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:219:62: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+        #t359.{core::List::add}{Invariant}(let final<BottomType> #t360 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:219:62: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   <String>[for (int i = 0; oracle(\"foo\"); i++) if (oracle()) 42 else 3.14];
                                                              ^" in 42 as{TypeError} core::String*);
       else
-        #t359.{core::List::add}(let final<BottomType> #t361 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:219:70: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
+        #t359.{core::List::add}{Invariant}(let final<BottomType> #t361 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:219:70: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
   <String>[for (int i = 0; oracle(\"foo\"); i++) if (oracle()) 42 else 3.14];
                                                                      ^" in 3.14 as{TypeError} core::String*);
   } =>#t359;
@@ -1935,50 +1935,50 @@
     final core::Set<core::String*>* #t362 = col::LinkedHashSet::•<core::String*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t362.{core::Set::add}(let final<BottomType> #t363 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:220:62: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+        #t362.{core::Set::add}{Invariant}(let final<BottomType> #t363 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:220:62: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   <String>{for (int i = 0; oracle(\"foo\"); i++) if (oracle()) 42 else 3.14, null};
                                                              ^" in 42 as{TypeError} core::String*);
       else
-        #t362.{core::Set::add}(let final<BottomType> #t364 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:220:70: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
+        #t362.{core::Set::add}{Invariant}(let final<BottomType> #t364 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:220:70: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
   <String>{for (int i = 0; oracle(\"foo\"); i++) if (oracle()) 42 else 3.14, null};
                                                                      ^" in 3.14 as{TypeError} core::String*);
-    #t362.{core::Set::add}(null);
+    #t362.{core::Set::add}{Invariant}(null);
   } =>#t362;
   block {
     final core::Map<core::String*, core::String*>* #t365 = <core::String*, core::String*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t365.{core::Map::[]=}("bar", let final<BottomType> #t366 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:221:77: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+        #t365.{core::Map::[]=}{Invariant}("bar", let final<BottomType> #t366 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:221:77: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   <String, String>{for (int i = 0; oracle(\"foo\"); i++) if (oracle()) \"bar\": 42 else \"bar\": 3.14, \"baz\": null};
                                                                             ^" in 42 as{TypeError} core::String*);
       else
-        #t365.{core::Map::[]=}("bar", let final<BottomType> #t367 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:221:92: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
+        #t365.{core::Map::[]=}{Invariant}("bar", let final<BottomType> #t367 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:221:92: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
   <String, String>{for (int i = 0; oracle(\"foo\"); i++) if (oracle()) \"bar\": 42 else \"bar\": 3.14, \"baz\": null};
                                                                                            ^" in 3.14 as{TypeError} core::String*);
-    #t365.{core::Map::[]=}("baz", null);
+    #t365.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t365;
   block {
     final core::List<core::int*>* #t368 = <core::int*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t368.{core::List::add}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:222:62: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+        #t368.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:222:62: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>[for (int i = 0; oracle(\"foo\"); i++) if (oracle()) ...map else 42];
                                                              ^");
       else
-        #t368.{core::List::add}(42);
+        #t368.{core::List::add}{Invariant}(42);
   } =>#t368;
   block {
     final core::Set<core::int*>* #t369 = col::LinkedHashSet::•<core::int*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t369.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:223:62: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+        #t369.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:223:62: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>{for (int i = 0; oracle(\"foo\"); i++) if (oracle()) ...map else 42, null};
                                                              ^");
       else
-        #t369.{core::Set::add}(42);
-    #t369.{core::Set::add}(null);
+        #t369.{core::Set::add}{Invariant}(42);
+    #t369.{core::Set::add}{Invariant}(null);
   } =>#t369;
   <core::String*, core::int*>{invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:224:70: Error: Unexpected type 'List<int>' of a map spread entry.  Expected 'dynamic' or a Map.
  - 'List' is from 'dart:core'.
@@ -1991,9 +1991,9 @@
     final core::List<core::int*>* #t370 = <core::int*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t370.{core::List::add}(42);
+        #t370.{core::List::add}{Invariant}(42);
       else
-        #t370.{core::List::add}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:225:70: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+        #t370.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:225:70: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>[for (int i = 0; oracle(\"foo\"); i++) if (oracle()) 42 else ...map];
                                                                      ^");
@@ -2002,13 +2002,13 @@
     final core::Set<core::int*>* #t371 = col::LinkedHashSet::•<core::int*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t371.{core::Set::add}(42);
+        #t371.{core::Set::add}{Invariant}(42);
       else
-        #t371.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:226:70: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+        #t371.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:226:70: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>{for (int i = 0; oracle(\"foo\"); i++) if (oracle()) 42 else ...map, null};
                                                                      ^");
-    #t371.{core::Set::add}(null);
+    #t371.{core::Set::add}{Invariant}(null);
   } =>#t371;
   <core::String*, core::int*>{invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:227:85: Error: Unexpected type 'List<int>' of a map spread entry.  Expected 'dynamic' or a Map.
  - 'List' is from 'dart:core'.
@@ -2024,7 +2024,7 @@
       invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:230:14: Error: Can't assign to the final variable 'i'.
   <int>[for (i in <int>[1]) i];
              ^";
-      #t372.{core::List::add}(i);
+      #t372.{core::List::add}{Invariant}(i);
     }
   } =>#t372;
   block {
@@ -2033,9 +2033,9 @@
       invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:231:14: Error: Can't assign to the final variable 'i'.
   <int>{for (i in <int>[1]) i, null};
              ^";
-      #t374.{core::Set::add}(i);
+      #t374.{core::Set::add}{Invariant}(i);
     }
-    #t374.{core::Set::add}(null);
+    #t374.{core::Set::add}{Invariant}(null);
   } =>#t374;
   block {
     final core::Map<core::String*, core::int*>* #t376 = <core::String*, core::int*>{};
@@ -2043,9 +2043,9 @@
       invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:232:21: Error: Can't assign to the final variable 'i'.
 \t<String, int>{for (i in <int>[1]) \"bar\": i, \"baz\": null};
 \t                   ^";
-      #t376.{core::Map::[]=}("bar", i);
+      #t376.{core::Map::[]=}{Invariant}("bar", i);
     }
-    #t376.{core::Map::[]=}("baz", null);
+    #t376.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t376;
   core::List<dynamic>* list10 = block {
     final core::List<dynamic>* #t378 = <dynamic>[];
@@ -2053,7 +2053,7 @@
  - 'Iterable' is from 'dart:core'.
   var list10 = [for (var i in \"not iterable\") i];
                               ^" in "not iterable" as{TypeError} core::Iterable<dynamic>*)
-      #t378.{core::List::add}(i);
+      #t378.{core::List::add}{Invariant}(i);
   } =>#t378;
   core::Set<dynamic>* set10 = block {
     final core::Set<dynamic>* #t380 = col::LinkedHashSet::•<dynamic>();
@@ -2061,8 +2061,8 @@
  - 'Iterable' is from 'dart:core'.
   var set10 = {for (var i in \"not iterable\") i, null};
                              ^" in "not iterable" as{TypeError} core::Iterable<dynamic>*)
-      #t380.{core::Set::add}(i);
-    #t380.{core::Set::add}(null);
+      #t380.{core::Set::add}{Invariant}(i);
+    #t380.{core::Set::add}{Invariant}(null);
   } =>#t380;
   core::Map<core::String*, dynamic>* map10 = block {
     final core::Map<core::String*, dynamic>* #t382 = <core::String*, dynamic>{};
@@ -2070,8 +2070,8 @@
  - 'Iterable' is from 'dart:core'.
   var map10 = {for (var i in \"not iterable\") \"bar\": i, \"baz\": null};
                              ^" in "not iterable" as{TypeError} core::Iterable<dynamic>*)
-      #t382.{core::Map::[]=}("bar", i);
-    #t382.{core::Map::[]=}("baz", null);
+      #t382.{core::Map::[]=}{Invariant}("bar", i);
+    #t382.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t382;
   core::List<core::int*>* list20 = block {
     final core::List<core::int*>* #t384 = <core::int*>[];
@@ -2080,7 +2080,7 @@
                                ^" in "not" as{TypeError} core::int*, let final<BottomType> #t386 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:237:39: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   var list20 = [for (int i in [\"not\", \"int\"]) i];
                                       ^" in "int" as{TypeError} core::int*])
-      #t384.{core::List::add}(i);
+      #t384.{core::List::add}{Invariant}(i);
   } =>#t384;
   core::Set<core::int*>* set20 = block {
     final core::Set<core::int*>* #t387 = col::LinkedHashSet::•<core::int*>();
@@ -2089,8 +2089,8 @@
                               ^" in "not" as{TypeError} core::int*, let final<BottomType> #t389 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:238:38: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   var set20 = {for (int i in [\"not\", \"int\"]) i, null};
                                      ^" in "int" as{TypeError} core::int*])
-      #t387.{core::Set::add}(i);
-    #t387.{core::Set::add}(null);
+      #t387.{core::Set::add}{Invariant}(i);
+    #t387.{core::Set::add}{Invariant}(null);
   } =>#t387;
   core::Map<core::String*, core::int*>* map20 = block {
     final core::Map<core::String*, core::int*>* #t390 = <core::String*, core::int*>{};
@@ -2099,8 +2099,8 @@
                               ^" in "not" as{TypeError} core::int*, let final<BottomType> #t392 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:239:38: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   var map20 = {for (int i in [\"not\", \"int\"]) \"bar\": i, \"baz\": null};
                                      ^" in "int" as{TypeError} core::int*])
-      #t390.{core::Map::[]=}("bar", i);
-    #t390.{core::Map::[]=}("baz", null);
+      #t390.{core::Map::[]=}{Invariant}("bar", i);
+    #t390.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t390;
   core::List<dynamic>* list30 = block {
     final core::List<dynamic>* #t393 = <dynamic>[];
@@ -2108,7 +2108,7 @@
  - 'Stream' is from 'dart:async'.
   var list30 = [await for (var i in \"not stream\") i];
                                     ^" in "not stream" as{TypeError} asy::Stream<dynamic>*)
-      #t393.{core::List::add}(i);
+      #t393.{core::List::add}{Invariant}(i);
   } =>#t393;
   core::Set<dynamic>* set30 = block {
     final core::Set<dynamic>* #t395 = col::LinkedHashSet::•<dynamic>();
@@ -2116,8 +2116,8 @@
  - 'Stream' is from 'dart:async'.
   var set30 = {await for (var i in \"not stream\") i, null};
                                    ^" in "not stream" as{TypeError} asy::Stream<dynamic>*)
-      #t395.{core::Set::add}(i);
-    #t395.{core::Set::add}(null);
+      #t395.{core::Set::add}{Invariant}(i);
+    #t395.{core::Set::add}{Invariant}(null);
   } =>#t395;
   core::Map<core::String*, dynamic>* map30 = block {
     final core::Map<core::String*, dynamic>* #t397 = <core::String*, dynamic>{};
@@ -2125,8 +2125,8 @@
  - 'Stream' is from 'dart:async'.
   var map30 = {await for (var i in \"not stream\") \"bar\": i, \"baz\": null};
                                    ^" in "not stream" as{TypeError} asy::Stream<dynamic>*)
-      #t397.{core::Map::[]=}("bar", i);
-    #t397.{core::Map::[]=}("baz", null);
+      #t397.{core::Map::[]=}{Invariant}("bar", i);
+    #t397.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t397;
   core::List<core::int*>* list40 = block {
     final core::List<core::int*>* #t399 = <core::int*>[];
@@ -2135,7 +2135,7 @@
                                                          ^" in "not" as{TypeError} core::int*, let final<BottomType> #t401 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:243:65: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   var list40 = [await for (int i in Stream.fromIterable([\"not\", \"int\"])) i];
                                                                 ^" in "int" as{TypeError} core::int*]))
-      #t399.{core::List::add}(i);
+      #t399.{core::List::add}{Invariant}(i);
   } =>#t399;
   core::Set<core::int*>* set40 = block {
     final core::Set<core::int*>* #t402 = col::LinkedHashSet::•<core::int*>();
@@ -2144,8 +2144,8 @@
                                                         ^" in "not" as{TypeError} core::int*, let final<BottomType> #t404 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:244:64: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   var set40 = {await for (int i in Stream.fromIterable([\"not\", \"int\"])) i, null};
                                                                ^" in "int" as{TypeError} core::int*]))
-      #t402.{core::Set::add}(i);
-    #t402.{core::Set::add}(null);
+      #t402.{core::Set::add}{Invariant}(i);
+    #t402.{core::Set::add}{Invariant}(null);
   } =>#t402;
   core::Map<core::String*, core::int*>* map40 = block {
     final core::Map<core::String*, core::int*>* #t405 = <core::String*, core::int*>{};
@@ -2154,82 +2154,82 @@
                                                         ^" in "not" as{TypeError} core::int*, let final<BottomType> #t407 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:245:64: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   var map40 = {await for (int i in Stream.fromIterable([\"not\", \"int\"])) \"bar\": i, \"baz\": null};
                                                                ^" in "int" as{TypeError} core::int*]))
-      #t405.{core::Map::[]=}("bar", i);
-    #t405.{core::Map::[]=}("baz", null);
+      #t405.{core::Map::[]=}{Invariant}("bar", i);
+    #t405.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t405;
   core::List<core::int*>* list50 = block {
     final core::List<core::int*>* #t408 = <core::int*>[];
     for (; ; )
-      #t408.{core::List::add}(42);
+      #t408.{core::List::add}{Invariant}(42);
   } =>#t408;
   core::Set<core::int*>* set50 = block {
     final core::Set<core::int*>* #t409 = col::LinkedHashSet::•<core::int*>();
     for (; ; )
-      #t409.{core::Set::add}(42);
-    #t409.{core::Set::add}(null);
+      #t409.{core::Set::add}{Invariant}(42);
+    #t409.{core::Set::add}{Invariant}(null);
   } =>#t409;
   core::Map<core::String*, core::int*>* map50 = block {
     final core::Map<core::String*, core::int*>* #t410 = <core::String*, core::int*>{};
     for (; ; )
-      #t410.{core::Map::[]=}("bar", 42);
-    #t410.{core::Map::[]=}("baz", null);
+      #t410.{core::Map::[]=}{Invariant}("bar", 42);
+    #t410.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t410;
   core::List<core::int*>* list60 = block {
     final core::List<core::int*>* #t411 = <core::int*>[];
     for (; let final<BottomType> #t412 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:249:24: Error: A value of type 'String' can't be assigned to a variable of type 'bool'.
   var list60 = [for (; \"not bool\";) 42];
                        ^" in "not bool" as{TypeError} core::bool*; )
-      #t411.{core::List::add}(42);
+      #t411.{core::List::add}{Invariant}(42);
   } =>#t411;
   core::Set<core::int*>* set60 = block {
     final core::Set<core::int*>* #t413 = col::LinkedHashSet::•<core::int*>();
     for (; let final<BottomType> #t414 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:250:23: Error: A value of type 'String' can't be assigned to a variable of type 'bool'.
   var set60 = {for (; \"not bool\";) 42, null};
                       ^" in "not bool" as{TypeError} core::bool*; )
-      #t413.{core::Set::add}(42);
-    #t413.{core::Set::add}(null);
+      #t413.{core::Set::add}{Invariant}(42);
+    #t413.{core::Set::add}{Invariant}(null);
   } =>#t413;
   core::Map<core::String*, core::int*>* map60 = block {
     final core::Map<core::String*, core::int*>* #t415 = <core::String*, core::int*>{};
     for (; let final<BottomType> #t416 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:251:23: Error: A value of type 'String' can't be assigned to a variable of type 'bool'.
   var map60 = {for (; \"not bool\";) \"bar\": 42, \"baz\": null};
                       ^" in "not bool" as{TypeError} core::bool*; )
-      #t415.{core::Map::[]=}("bar", 42);
-    #t415.{core::Map::[]=}("baz", null);
+      #t415.{core::Map::[]=}{Invariant}("bar", 42);
+    #t415.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t415;
 }
 static method testForElementErrorsNotAsync(asy::Stream<core::int*>* stream) → dynamic {
   block {
     final core::List<core::int*>* #t417 = <core::int*>[];
     await for (core::int* i in stream)
-      #t417.{core::List::add}(i);
+      #t417.{core::List::add}{Invariant}(i);
   } =>#t417;
   block {
     final core::Set<core::int*>* #t418 = col::LinkedHashSet::•<core::int*>();
     await for (core::int* i in stream)
-      #t418.{core::Set::add}(i);
+      #t418.{core::Set::add}{Invariant}(i);
   } =>#t418;
   block {
     final core::Map<core::String*, core::int*>* #t419 = <core::String*, core::int*>{};
     await for (core::int* i in stream)
-      #t419.{core::Map::[]=}("bar", i);
+      #t419.{core::Map::[]=}{Invariant}("bar", i);
   } =>#t419;
 }
 static method testPromotion(self::A* a) → dynamic {
   core::List<core::int*>* list10 = block {
     final core::List<core::int*>* #t420 = <core::int*>[];
     if(a is self::B*)
-      #t420.{core::List::add}(a{self::B*}.{self::B::foo});
+      #t420.{core::List::add}{Invariant}(a{self::B*}.{self::B::foo});
   } =>#t420;
   core::Set<core::int*>* set10 = block {
     final core::Set<core::int*>* #t421 = col::LinkedHashSet::•<core::int*>();
     if(a is self::B*)
-      #t421.{core::Set::add}(a{self::B*}.{self::B::foo});
+      #t421.{core::Set::add}{Invariant}(a{self::B*}.{self::B::foo});
   } =>#t421;
   core::Map<core::int*, core::int*>* map10 = block {
     final core::Map<core::int*, core::int*>* #t422 = <core::int*, core::int*>{};
     if(a is self::B*)
-      #t422.{core::Map::[]=}(a{self::B*}.{self::B::foo}, a{self::B*}.{self::B::foo});
+      #t422.{core::Map::[]=}{Invariant}(a{self::B*}.{self::B::foo}, a{self::B*}.{self::B::foo});
   } =>#t422;
 }
 static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/general/control_flow_collection_inference.dart.strong.transformed.expect b/pkg/front_end/testcases/general/control_flow_collection_inference.dart.strong.transformed.expect
index ea88d5a..898ae52 100644
--- a/pkg/front_end/testcases/general/control_flow_collection_inference.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/general/control_flow_collection_inference.dart.strong.transformed.expect
@@ -455,53 +455,53 @@
   core::List<core::int*>* list10 = block {
     final core::List<core::int*>* #t1 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t1.{core::List::add}(42);
+      #t1.{core::List::add}{Invariant}(42);
   } =>#t1;
   core::Set<core::int*>* set10 = block {
     final core::Set<core::int*>* #t2 = new col::_CompactLinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t2.{core::Set::add}(42);
-    #t2.{core::Set::add}(null);
+      #t2.{core::Set::add}{Invariant}(42);
+    #t2.{core::Set::add}{Invariant}(null);
   } =>#t2;
   core::Map<core::String*, core::int*>* map10 = block {
     final core::Map<core::String*, core::int*>* #t3 = <core::String*, core::int*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t3.{core::Map::[]=}("bar", 42);
-    #t3.{core::Map::[]=}("baz", null);
+      #t3.{core::Map::[]=}{Invariant}("bar", 42);
+    #t3.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t3;
   core::List<dynamic>* list11 = block {
     final core::List<dynamic>* #t4 = <dynamic>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t4.{core::List::add}(dynVar);
+      #t4.{core::List::add}{Invariant}(dynVar);
   } =>#t4;
   core::Set<dynamic>* set11 = block {
     final core::Set<dynamic>* #t5 = new col::_CompactLinkedHashSet::•<dynamic>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t5.{core::Set::add}(dynVar);
-    #t5.{core::Set::add}(null);
+      #t5.{core::Set::add}{Invariant}(dynVar);
+    #t5.{core::Set::add}{Invariant}(null);
   } =>#t5;
   core::Map<core::String*, dynamic>* map11 = block {
     final core::Map<core::String*, dynamic>* #t6 = <core::String*, dynamic>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t6.{core::Map::[]=}("bar", dynVar);
-    #t6.{core::Map::[]=}("baz", null);
+      #t6.{core::Map::[]=}{Invariant}("bar", dynVar);
+    #t6.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t6;
   core::List<core::List<core::int*>*>* list12 = block {
     final core::List<core::List<core::int*>*>* #t7 = <core::List<core::int*>*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t7.{core::List::add}(<core::int*>[42]);
+      #t7.{core::List::add}{Invariant}(<core::int*>[42]);
   } =>#t7;
   core::Set<core::List<core::int*>*>* set12 = block {
     final core::Set<core::List<core::int*>*>* #t8 = new col::_CompactLinkedHashSet::•<core::List<core::int*>*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t8.{core::Set::add}(<core::int*>[42]);
-    #t8.{core::Set::add}(null);
+      #t8.{core::Set::add}{Invariant}(<core::int*>[42]);
+    #t8.{core::Set::add}{Invariant}(null);
   } =>#t8;
   core::Map<core::String*, core::List<core::int*>*>* map12 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t9 = <core::String*, core::List<core::int*>*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t9.{core::Map::[]=}("bar", <core::int*>[42]);
-    #t9.{core::Map::[]=}("baz", null);
+      #t9.{core::Map::[]=}{Invariant}("bar", <core::int*>[42]);
+    #t9.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t9;
   core::List<core::int*>* list20 = block {
     final core::List<core::int*>* #t10 = <core::int*>[];
@@ -509,7 +509,7 @@
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[42].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t11 = :sync-for-iterator.{core::Iterator::current};
-        #t10.{core::List::add}(#t11);
+        #t10.{core::List::add}{Invariant}(#t11);
       }
     }
   } =>#t10;
@@ -519,10 +519,10 @@
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[42].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t13 = :sync-for-iterator.{core::Iterator::current};
-        #t12.{core::Set::add}(#t13);
+        #t12.{core::Set::add}{Invariant}(#t13);
       }
     }
-    #t12.{core::Set::add}(null);
+    #t12.{core::Set::add}{Invariant}(null);
   } =>#t12;
   core::Map<core::String*, core::int*>* map20 = block {
     final core::Map<core::String*, core::int*>* #t14 = <core::String*, core::int*>{};
@@ -530,10 +530,10 @@
       core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = <core::String*, core::int*>{"bar": 42}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::int*>* #t15 = :sync-for-iterator.{core::Iterator::current};
-        #t14.{core::Map::[]=}(#t15.{core::MapEntry::key}, #t15.{core::MapEntry::value});
+        #t14.{core::Map::[]=}{Invariant}(#t15.{core::MapEntry::key}, #t15.{core::MapEntry::value});
       }
     }
-    #t14.{core::Map::[]=}("baz", null);
+    #t14.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t14;
   core::List<dynamic>* list21 = block {
     final core::List<dynamic>* #t16 = <dynamic>[];
@@ -541,7 +541,7 @@
       core::Iterator<dynamic>* :sync-for-iterator = <dynamic>[dynVar].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final dynamic #t17 = :sync-for-iterator.{core::Iterator::current};
-        #t16.{core::List::add}(#t17);
+        #t16.{core::List::add}{Invariant}(#t17);
       }
     }
   } =>#t16;
@@ -551,10 +551,10 @@
       core::Iterator<dynamic>* :sync-for-iterator = <dynamic>[dynVar].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final dynamic #t19 = :sync-for-iterator.{core::Iterator::current};
-        #t18.{core::Set::add}(#t19);
+        #t18.{core::Set::add}{Invariant}(#t19);
       }
     }
-    #t18.{core::Set::add}(null);
+    #t18.{core::Set::add}{Invariant}(null);
   } =>#t18;
   core::Map<core::String*, dynamic>* map21 = block {
     final core::Map<core::String*, dynamic>* #t20 = <core::String*, dynamic>{};
@@ -562,10 +562,10 @@
       core::Iterator<core::MapEntry<core::String*, dynamic>>* :sync-for-iterator = <core::String*, dynamic>{"bar": dynVar}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, dynamic>* #t21 = :sync-for-iterator.{core::Iterator::current};
-        #t20.{core::Map::[]=}(#t21.{core::MapEntry::key}, #t21.{core::MapEntry::value});
+        #t20.{core::Map::[]=}{Invariant}(#t21.{core::MapEntry::key}, #t21.{core::MapEntry::value});
       }
     }
-    #t20.{core::Map::[]=}("baz", null);
+    #t20.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t20;
   core::List<core::List<core::int*>*>* list22 = block {
     final core::List<core::List<core::int*>*>* #t22 = <core::List<core::int*>*>[];
@@ -573,7 +573,7 @@
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[42]].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t23 = :sync-for-iterator.{core::Iterator::current};
-        #t22.{core::List::add}(#t23);
+        #t22.{core::List::add}{Invariant}(#t23);
       }
     }
   } =>#t22;
@@ -583,10 +583,10 @@
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[42]].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t25 = :sync-for-iterator.{core::Iterator::current};
-        #t24.{core::Set::add}(#t25);
+        #t24.{core::Set::add}{Invariant}(#t25);
       }
     }
-    #t24.{core::Set::add}(null);
+    #t24.{core::Set::add}{Invariant}(null);
   } =>#t24;
   core::Map<core::String*, core::List<core::int*>*>* map22 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t26 = <core::String*, core::List<core::int*>*>{};
@@ -594,10 +594,10 @@
       core::Iterator<core::MapEntry<core::String*, core::List<core::int*>*>>* :sync-for-iterator = <core::String*, core::List<core::int*>*>{"bar": <core::int*>[42]}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::List<core::int*>*>* #t27 = :sync-for-iterator.{core::Iterator::current};
-        #t26.{core::Map::[]=}(#t27.{core::MapEntry::key}, #t27.{core::MapEntry::value});
+        #t26.{core::Map::[]=}{Invariant}(#t27.{core::MapEntry::key}, #t27.{core::MapEntry::value});
       }
     }
-    #t26.{core::Map::[]=}("baz", null);
+    #t26.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t26;
   core::List<core::int*>* list30 = block {
     final core::List<core::int*>* #t28 = <core::int*>[];
@@ -606,7 +606,7 @@
         core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[42].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::int* #t29 = :sync-for-iterator.{core::Iterator::current};
-          #t28.{core::List::add}(#t29);
+          #t28.{core::List::add}{Invariant}(#t29);
         }
       }
   } =>#t28;
@@ -617,10 +617,10 @@
         core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[42].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::int* #t31 = :sync-for-iterator.{core::Iterator::current};
-          #t30.{core::Set::add}(#t31);
+          #t30.{core::Set::add}{Invariant}(#t31);
         }
       }
-    #t30.{core::Set::add}(null);
+    #t30.{core::Set::add}{Invariant}(null);
   } =>#t30;
   core::Map<core::String*, core::int*>* map30 = block {
     final core::Map<core::String*, core::int*>* #t32 = <core::String*, core::int*>{};
@@ -629,10 +629,10 @@
         core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = <core::String*, core::int*>{"bar": 42}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::String*, core::int*>* #t33 = :sync-for-iterator.{core::Iterator::current};
-          #t32.{core::Map::[]=}(#t33.{core::MapEntry::key}, #t33.{core::MapEntry::value});
+          #t32.{core::Map::[]=}{Invariant}(#t33.{core::MapEntry::key}, #t33.{core::MapEntry::value});
         }
       }
-    #t32.{core::Map::[]=}("baz", null);
+    #t32.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t32;
   core::List<dynamic>* list31 = block {
     final core::List<dynamic>* #t34 = <dynamic>[];
@@ -641,7 +641,7 @@
         core::Iterator<dynamic>* :sync-for-iterator = <dynamic>[dynVar].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final dynamic #t35 = :sync-for-iterator.{core::Iterator::current};
-          #t34.{core::List::add}(#t35);
+          #t34.{core::List::add}{Invariant}(#t35);
         }
       }
   } =>#t34;
@@ -652,10 +652,10 @@
         core::Iterator<dynamic>* :sync-for-iterator = <dynamic>[dynVar].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final dynamic #t37 = :sync-for-iterator.{core::Iterator::current};
-          #t36.{core::Set::add}(#t37);
+          #t36.{core::Set::add}{Invariant}(#t37);
         }
       }
-    #t36.{core::Set::add}(null);
+    #t36.{core::Set::add}{Invariant}(null);
   } =>#t36;
   core::Map<core::String*, dynamic>* map31 = block {
     final core::Map<core::String*, dynamic>* #t38 = <core::String*, dynamic>{};
@@ -664,10 +664,10 @@
         core::Iterator<core::MapEntry<core::String*, dynamic>>* :sync-for-iterator = <core::String*, dynamic>{"bar": dynVar}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::String*, dynamic>* #t39 = :sync-for-iterator.{core::Iterator::current};
-          #t38.{core::Map::[]=}(#t39.{core::MapEntry::key}, #t39.{core::MapEntry::value});
+          #t38.{core::Map::[]=}{Invariant}(#t39.{core::MapEntry::key}, #t39.{core::MapEntry::value});
         }
       }
-    #t38.{core::Map::[]=}("baz", null);
+    #t38.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t38;
   core::List<core::List<core::int*>*>* list33 = block {
     final core::List<core::List<core::int*>*>* #t40 = <core::List<core::int*>*>[];
@@ -676,7 +676,7 @@
         core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[42]].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::List<core::int*>* #t41 = :sync-for-iterator.{core::Iterator::current};
-          #t40.{core::List::add}(#t41);
+          #t40.{core::List::add}{Invariant}(#t41);
         }
       }
   } =>#t40;
@@ -687,10 +687,10 @@
         core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[42]].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::List<core::int*>* #t43 = :sync-for-iterator.{core::Iterator::current};
-          #t42.{core::Set::add}(#t43);
+          #t42.{core::Set::add}{Invariant}(#t43);
         }
       }
-    #t42.{core::Set::add}(null);
+    #t42.{core::Set::add}{Invariant}(null);
   } =>#t42;
   core::Map<core::String*, core::List<core::int*>*>* map33 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t44 = <core::String*, core::List<core::int*>*>{};
@@ -699,10 +699,10 @@
         core::Iterator<core::MapEntry<core::String*, core::List<core::int*>*>>* :sync-for-iterator = <core::String*, core::List<core::int*>*>{"bar": <core::int*>[42]}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::String*, core::List<core::int*>*>* #t45 = :sync-for-iterator.{core::Iterator::current};
-          #t44.{core::Map::[]=}(#t45.{core::MapEntry::key}, #t45.{core::MapEntry::value});
+          #t44.{core::Map::[]=}{Invariant}(#t45.{core::MapEntry::key}, #t45.{core::MapEntry::value});
         }
       }
-    #t44.{core::Map::[]=}("baz", null);
+    #t44.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t44;
   core::List<core::List<core::int*>*>* list40 = block {
     final core::List<core::List<core::int*>*>* #t46 = <core::List<core::int*>*>[];
@@ -710,7 +710,7 @@
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t47 = :sync-for-iterator.{core::Iterator::current};
-        #t46.{core::List::add}(#t47);
+        #t46.{core::List::add}{Invariant}(#t47);
       }
     }
   } =>#t46;
@@ -720,10 +720,10 @@
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t49 = :sync-for-iterator.{core::Iterator::current};
-        #t48.{core::Set::add}(#t49);
+        #t48.{core::Set::add}{Invariant}(#t49);
       }
     }
-    #t48.{core::Set::add}(null);
+    #t48.{core::Set::add}{Invariant}(null);
   } =>#t48;
   core::Map<core::String*, core::List<core::int*>*>* map40 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:39:34: Error: Both Iterable and Map spread elements encountered in ambiguous literal.
   Map<String, List<int>> map40 = {if (oracle(\"foo\")) ...{\"bar\", []}, \"baz\": null};
@@ -733,11 +733,11 @@
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*) {
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = ( block {
         final core::Set<core::List<core::int*>*>* #t51 = new col::_CompactLinkedHashSet::•<core::List<core::int*>*>();
-        #t51.{core::Set::add}(<core::int*>[]);
+        #t51.{core::Set::add}{Invariant}(<core::int*>[]);
       } =>#t51).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t52 = :sync-for-iterator.{core::Iterator::current};
-        #t50.{core::List::add}(#t52);
+        #t50.{core::List::add}{Invariant}(#t52);
       }
     }
   } =>#t50;
@@ -746,14 +746,14 @@
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*) {
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = ( block {
         final core::Set<core::List<core::int*>*>* #t54 = new col::_CompactLinkedHashSet::•<core::List<core::int*>*>();
-        #t54.{core::Set::add}(<core::int*>[]);
+        #t54.{core::Set::add}{Invariant}(<core::int*>[]);
       } =>#t54).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t55 = :sync-for-iterator.{core::Iterator::current};
-        #t53.{core::Set::add}(#t55);
+        #t53.{core::Set::add}{Invariant}(#t55);
       }
     }
-    #t53.{core::Set::add}(null);
+    #t53.{core::Set::add}{Invariant}(null);
   } =>#t53;
   core::List<core::List<core::int*>*>* list42 = block {
     final core::List<core::List<core::int*>*>* #t56 = <core::List<core::int*>*>[];
@@ -762,7 +762,7 @@
         core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::List<core::int*>* #t57 = :sync-for-iterator.{core::Iterator::current};
-          #t56.{core::List::add}(#t57);
+          #t56.{core::List::add}{Invariant}(#t57);
         }
       }
   } =>#t56;
@@ -773,10 +773,10 @@
         core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::List<core::int*>* #t59 = :sync-for-iterator.{core::Iterator::current};
-          #t58.{core::Set::add}(#t59);
+          #t58.{core::Set::add}{Invariant}(#t59);
         }
       }
-    #t58.{core::Set::add}(null);
+    #t58.{core::Set::add}{Invariant}(null);
   } =>#t58;
   core::Map<core::String*, core::List<core::int*>*>* map42 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t60 = <core::String*, core::List<core::int*>*>{};
@@ -785,10 +785,10 @@
         core::Iterator<core::MapEntry<core::String*, core::List<core::int*>*>>* :sync-for-iterator = <core::String*, core::List<core::int*>*>{"bar": <core::int*>[]}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::String*, core::List<core::int*>*>* #t61 = :sync-for-iterator.{core::Iterator::current};
-          #t60.{core::Map::[]=}(#t61.{core::MapEntry::key}, #t61.{core::MapEntry::value});
+          #t60.{core::Map::[]=}{Invariant}(#t61.{core::MapEntry::key}, #t61.{core::MapEntry::value});
         }
       }
-    #t60.{core::Map::[]=}("baz", null);
+    #t60.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t60;
   core::List<core::int*>* list50 = block {
     final core::List<core::int*>* #t62 = <core::int*>[];
@@ -796,7 +796,7 @@
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t63 = :sync-for-iterator.{core::Iterator::current};
-        #t62.{core::List::add}(#t63);
+        #t62.{core::List::add}{Invariant}(#t63);
       }
     }
   } =>#t62;
@@ -806,10 +806,10 @@
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t65 = :sync-for-iterator.{core::Iterator::current};
-        #t64.{core::Set::add}(#t65);
+        #t64.{core::Set::add}{Invariant}(#t65);
       }
     }
-    #t64.{core::Set::add}(null);
+    #t64.{core::Set::add}{Invariant}(null);
   } =>#t64;
   core::Map<core::String*, core::int*>* map50 = block {
     final core::Map<core::String*, core::int*>* #t66 = <core::String*, core::int*>{};
@@ -817,10 +817,10 @@
       core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = <core::String*, core::int*>{}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::int*>* #t67 = :sync-for-iterator.{core::Iterator::current};
-        #t66.{core::Map::[]=}(#t67.{core::MapEntry::key}, #t67.{core::MapEntry::value});
+        #t66.{core::Map::[]=}{Invariant}(#t67.{core::MapEntry::key}, #t67.{core::MapEntry::value});
       }
     }
-    #t66.{core::Map::[]=}("baz", null);
+    #t66.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t66;
   core::List<core::int*>* list51 = block {
     final core::List<core::int*>* #t68 = <core::int*>[];
@@ -830,7 +830,7 @@
       } =>#t69).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t70 = :sync-for-iterator.{core::Iterator::current};
-        #t68.{core::List::add}(#t70);
+        #t68.{core::List::add}{Invariant}(#t70);
       }
     }
   } =>#t68;
@@ -842,10 +842,10 @@
       } =>#t72).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t73 = :sync-for-iterator.{core::Iterator::current};
-        #t71.{core::Set::add}(#t73);
+        #t71.{core::Set::add}{Invariant}(#t73);
       }
     }
-    #t71.{core::Set::add}(null);
+    #t71.{core::Set::add}{Invariant}(null);
   } =>#t71;
   core::List<core::int*>* list52 = block {
     final core::List<core::int*>* #t74 = <core::int*>[];
@@ -854,7 +854,7 @@
         core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::int* #t75 = :sync-for-iterator.{core::Iterator::current};
-          #t74.{core::List::add}(#t75);
+          #t74.{core::List::add}{Invariant}(#t75);
         }
       }
   } =>#t74;
@@ -865,10 +865,10 @@
         core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::int* #t77 = :sync-for-iterator.{core::Iterator::current};
-          #t76.{core::Set::add}(#t77);
+          #t76.{core::Set::add}{Invariant}(#t77);
         }
       }
-    #t76.{core::Set::add}(null);
+    #t76.{core::Set::add}{Invariant}(null);
   } =>#t76;
   core::Map<core::String*, core::int*>* map52 = block {
     final core::Map<core::String*, core::int*>* #t78 = <core::String*, core::int*>{};
@@ -877,10 +877,10 @@
         core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = <core::String*, core::int*>{}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::String*, core::int*>* #t79 = :sync-for-iterator.{core::Iterator::current};
-          #t78.{core::Map::[]=}(#t79.{core::MapEntry::key}, #t79.{core::MapEntry::value});
+          #t78.{core::Map::[]=}{Invariant}(#t79.{core::MapEntry::key}, #t79.{core::MapEntry::value});
         }
       }
-    #t78.{core::Map::[]=}("baz", null);
+    #t78.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t78;
   core::List<core::List<core::int*>*>* list60 = block {
     final core::List<core::List<core::int*>*>* #t80 = <core::List<core::int*>*>[];
@@ -888,7 +888,7 @@
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t81 = :sync-for-iterator.{core::Iterator::current};
-        #t80.{core::List::add}(#t81);
+        #t80.{core::List::add}{Invariant}(#t81);
       }
     }
   } =>#t80;
@@ -898,10 +898,10 @@
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t83 = :sync-for-iterator.{core::Iterator::current};
-        #t82.{core::Set::add}(#t83);
+        #t82.{core::Set::add}{Invariant}(#t83);
       }
     }
-    #t82.{core::Set::add}(null);
+    #t82.{core::Set::add}{Invariant}(null);
   } =>#t82;
   core::Map<core::String*, core::List<core::int*>*>* map60 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t84 = <core::String*, core::List<core::int*>*>{};
@@ -909,10 +909,10 @@
       core::Iterator<core::MapEntry<core::String*, core::List<core::int*>*>>* :sync-for-iterator = <core::String*, core::List<core::int*>*>{"bar": <core::int*>[]}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::List<core::int*>*>* #t85 = :sync-for-iterator.{core::Iterator::current};
-        #t84.{core::Map::[]=}(#t85.{core::MapEntry::key}, #t85.{core::MapEntry::value});
+        #t84.{core::Map::[]=}{Invariant}(#t85.{core::MapEntry::key}, #t85.{core::MapEntry::value});
       }
     }
-    #t84.{core::Map::[]=}("baz", null);
+    #t84.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t84;
   core::List<core::List<core::int*>*>* list61 = block {
     final core::List<core::List<core::int*>*>* #t86 = <core::List<core::int*>*>[];
@@ -921,7 +921,7 @@
         core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::List<core::int*>* #t87 = :sync-for-iterator.{core::Iterator::current};
-          #t86.{core::List::add}(#t87);
+          #t86.{core::List::add}{Invariant}(#t87);
         }
       }
   } =>#t86;
@@ -932,10 +932,10 @@
         core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::List<core::int*>* #t89 = :sync-for-iterator.{core::Iterator::current};
-          #t88.{core::Set::add}(#t89);
+          #t88.{core::Set::add}{Invariant}(#t89);
         }
       }
-    #t88.{core::Set::add}(null);
+    #t88.{core::Set::add}{Invariant}(null);
   } =>#t88;
   core::Map<core::String*, core::List<core::int*>*>* map61 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t90 = <core::String*, core::List<core::int*>*>{};
@@ -944,57 +944,57 @@
         core::Iterator<core::MapEntry<core::String*, core::List<core::int*>*>>* :sync-for-iterator = <core::String*, core::List<core::int*>*>{"bar": <core::int*>[]}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::String*, core::List<core::int*>*>* #t91 = :sync-for-iterator.{core::Iterator::current};
-          #t90.{core::Map::[]=}(#t91.{core::MapEntry::key}, #t91.{core::MapEntry::value});
+          #t90.{core::Map::[]=}{Invariant}(#t91.{core::MapEntry::key}, #t91.{core::MapEntry::value});
         }
       }
-    #t90.{core::Map::[]=}("baz", null);
+    #t90.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t90;
   core::List<core::List<core::int*>*>* list70 = block {
     final core::List<core::List<core::int*>*>* #t92 = <core::List<core::int*>*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t92.{core::List::add}(<core::int*>[]);
+      #t92.{core::List::add}{Invariant}(<core::int*>[]);
   } =>#t92;
   core::Set<core::List<core::int*>*>* set70 = block {
     final core::Set<core::List<core::int*>*>* #t93 = new col::_CompactLinkedHashSet::•<core::List<core::int*>*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t93.{core::Set::add}(<core::int*>[]);
-    #t93.{core::Set::add}(null);
+      #t93.{core::Set::add}{Invariant}(<core::int*>[]);
+    #t93.{core::Set::add}{Invariant}(null);
   } =>#t93;
   core::List<core::List<core::int*>*>* list71 = block {
     final core::List<core::List<core::int*>*>* #t94 = <core::List<core::int*>*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t94.{core::List::add}(<core::int*>[]);
+        #t94.{core::List::add}{Invariant}(<core::int*>[]);
   } =>#t94;
   core::Set<core::List<core::int*>*>* set71 = block {
     final core::Set<core::List<core::int*>*>* #t95 = new col::_CompactLinkedHashSet::•<core::List<core::int*>*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t95.{core::Set::add}(<core::int*>[]);
-    #t95.{core::Set::add}(null);
+        #t95.{core::Set::add}{Invariant}(<core::int*>[]);
+    #t95.{core::Set::add}{Invariant}(null);
   } =>#t95;
   core::List<core::num*>* list80 = block {
     final core::List<core::num*>* #t96 = <core::num*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t96.{core::List::add}(42);
+      #t96.{core::List::add}{Invariant}(42);
     else
-      #t96.{core::List::add}(3.14);
+      #t96.{core::List::add}{Invariant}(3.14);
   } =>#t96;
   core::Set<core::num*>* set80 = block {
     final core::Set<core::num*>* #t97 = new col::_CompactLinkedHashSet::•<core::num*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t97.{core::Set::add}(42);
+      #t97.{core::Set::add}{Invariant}(42);
     else
-      #t97.{core::Set::add}(3.14);
-    #t97.{core::Set::add}(null);
+      #t97.{core::Set::add}{Invariant}(3.14);
+    #t97.{core::Set::add}{Invariant}(null);
   } =>#t97;
   core::Map<core::String*, core::num*>* map80 = block {
     final core::Map<core::String*, core::num*>* #t98 = <core::String*, core::num*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t98.{core::Map::[]=}("bar", 42);
+      #t98.{core::Map::[]=}{Invariant}("bar", 42);
     else
-      #t98.{core::Map::[]=}("bar", 3.14);
-    #t98.{core::Map::[]=}("baz", null);
+      #t98.{core::Map::[]=}{Invariant}("bar", 3.14);
+    #t98.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t98;
   core::List<core::num*>* list81 = block {
     final core::List<core::num*>* #t99 = <core::num*>[];
@@ -1002,14 +1002,14 @@
       core::Iterator<core::int*>* :sync-for-iterator = listInt.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::num* #t100 = :sync-for-iterator.{core::Iterator::current};
-        #t99.{core::List::add}(#t100);
+        #t99.{core::List::add}{Invariant}(#t100);
       }
     }
     else {
       core::Iterator<core::double*>* :sync-for-iterator = listDouble.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::num* #t101 = :sync-for-iterator.{core::Iterator::current};
-        #t99.{core::List::add}(#t101);
+        #t99.{core::List::add}{Invariant}(#t101);
       }
     }
   } =>#t99;
@@ -1019,17 +1019,17 @@
       core::Iterator<core::int*>* :sync-for-iterator = listInt.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::num* #t103 = :sync-for-iterator.{core::Iterator::current};
-        #t102.{core::Set::add}(#t103);
+        #t102.{core::Set::add}{Invariant}(#t103);
       }
     }
     else {
       core::Iterator<core::double*>* :sync-for-iterator = listDouble.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::num* #t104 = :sync-for-iterator.{core::Iterator::current};
-        #t102.{core::Set::add}(#t104);
+        #t102.{core::Set::add}{Invariant}(#t104);
       }
     }
-    #t102.{core::Set::add}(null);
+    #t102.{core::Set::add}{Invariant}(null);
   } =>#t102;
   core::Map<core::String*, core::num*>* map81 = block {
     final core::Map<core::String*, core::num*>* #t105 = <core::String*, core::num*>{};
@@ -1037,17 +1037,17 @@
       core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = mapToInt.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::num*>* #t106 = :sync-for-iterator.{core::Iterator::current};
-        #t105.{core::Map::[]=}(#t106.{core::MapEntry::key}, #t106.{core::MapEntry::value});
+        #t105.{core::Map::[]=}{Invariant}(#t106.{core::MapEntry::key}, #t106.{core::MapEntry::value});
       }
     }
     else {
       core::Iterator<core::MapEntry<core::String*, core::double*>>* :sync-for-iterator = mapToDouble.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::num*>* #t107 = :sync-for-iterator.{core::Iterator::current};
-        #t105.{core::Map::[]=}(#t107.{core::MapEntry::key}, #t107.{core::MapEntry::value});
+        #t105.{core::Map::[]=}{Invariant}(#t107.{core::MapEntry::key}, #t107.{core::MapEntry::value});
       }
     }
-    #t105.{core::Map::[]=}("baz", null);
+    #t105.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t105;
   core::List<dynamic>* list82 = block {
     final core::List<dynamic>* #t108 = <dynamic>[];
@@ -1055,14 +1055,14 @@
       core::Iterator<core::int*>* :sync-for-iterator = listInt.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final dynamic #t109 = :sync-for-iterator.{core::Iterator::current};
-        #t108.{core::List::add}(#t109);
+        #t108.{core::List::add}{Invariant}(#t109);
       }
     }
     else {
       core::Iterator<dynamic>* :sync-for-iterator = (dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final dynamic #t110 = :sync-for-iterator.{core::Iterator::current};
-        #t108.{core::List::add}(#t110);
+        #t108.{core::List::add}{Invariant}(#t110);
       }
     }
   } =>#t108;
@@ -1072,22 +1072,22 @@
       core::Iterator<core::int*>* :sync-for-iterator = listInt.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final dynamic #t112 = :sync-for-iterator.{core::Iterator::current};
-        #t111.{core::Set::add}(#t112);
+        #t111.{core::Set::add}{Invariant}(#t112);
       }
     }
     else {
       core::Iterator<dynamic>* :sync-for-iterator = (dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final dynamic #t113 = :sync-for-iterator.{core::Iterator::current};
-        #t111.{core::Set::add}(#t113);
+        #t111.{core::Set::add}{Invariant}(#t113);
       }
     }
-    #t111.{core::Set::add}(null);
+    #t111.{core::Set::add}{Invariant}(null);
   } =>#t111;
   core::Set<dynamic>* map82 = block {
     final core::Set<dynamic>* #t114 = new col::_CompactLinkedHashSet::•<dynamic>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t114.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:71:38: Error: Unexpected type 'Map<String, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t114.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:71:38: Error: Unexpected type 'Map<String, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   var map82 = {if (oracle(\"foo\")) ...mapToInt else ...dynVar, null};
                                      ^");
@@ -1095,20 +1095,20 @@
       core::Iterator<dynamic>* :sync-for-iterator = (dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final dynamic #t115 = :sync-for-iterator.{core::Iterator::current};
-        #t114.{core::Set::add}(#t115);
+        #t114.{core::Set::add}{Invariant}(#t115);
       }
     }
-    #t114.{core::Set::add}(null);
+    #t114.{core::Set::add}{Invariant}(null);
   } =>#t114;
   core::List<core::num*>* list83 = block {
     final core::List<core::num*>* #t116 = <core::num*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t116.{core::List::add}(42);
+      #t116.{core::List::add}{Invariant}(42);
     else {
       core::Iterator<core::double*>* :sync-for-iterator = listDouble.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::num* #t117 = :sync-for-iterator.{core::Iterator::current};
-        #t116.{core::List::add}(#t117);
+        #t116.{core::List::add}{Invariant}(#t117);
       }
     }
   } =>#t116;
@@ -1118,12 +1118,12 @@
       core::Iterator<core::int*>* :sync-for-iterator = listInt.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::num* #t119 = :sync-for-iterator.{core::Iterator::current};
-        #t118.{core::Set::add}(#t119);
+        #t118.{core::Set::add}{Invariant}(#t119);
       }
     }
     else
-      #t118.{core::Set::add}(3.14);
-    #t118.{core::Set::add}(null);
+      #t118.{core::Set::add}{Invariant}(3.14);
+    #t118.{core::Set::add}{Invariant}(null);
   } =>#t118;
   core::Map<core::String*, core::num*>* map83 = block {
     final core::Map<core::String*, core::num*>* #t120 = <core::String*, core::num*>{};
@@ -1131,29 +1131,29 @@
       core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = mapToInt.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::num*>* #t121 = :sync-for-iterator.{core::Iterator::current};
-        #t120.{core::Map::[]=}(#t121.{core::MapEntry::key}, #t121.{core::MapEntry::value});
+        #t120.{core::Map::[]=}{Invariant}(#t121.{core::MapEntry::key}, #t121.{core::MapEntry::value});
       }
     }
     else
-      #t120.{core::Map::[]=}("bar", 3.14);
-    #t120.{core::Map::[]=}("baz", null);
+      #t120.{core::Map::[]=}{Invariant}("bar", 3.14);
+    #t120.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t120;
   core::List<core::int*>* list90 = block {
     final core::List<core::int*>* #t122 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t122.{core::List::add}(dynVar as{TypeError,ForDynamic} core::int*);
+      #t122.{core::List::add}{Invariant}(dynVar as{TypeError,ForDynamic} core::int*);
   } =>#t122;
   core::Set<core::int*>* set90 = block {
     final core::Set<core::int*>* #t123 = new col::_CompactLinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t123.{core::Set::add}(dynVar as{TypeError,ForDynamic} core::int*);
-    #t123.{core::Set::add}(null);
+      #t123.{core::Set::add}{Invariant}(dynVar as{TypeError,ForDynamic} core::int*);
+    #t123.{core::Set::add}{Invariant}(null);
   } =>#t123;
   core::Map<core::String*, core::int*>* map90 = block {
     final core::Map<core::String*, core::int*>* #t124 = <core::String*, core::int*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t124.{core::Map::[]=}("bar", dynVar as{TypeError,ForDynamic} core::int*);
-    #t124.{core::Map::[]=}("baz", null);
+      #t124.{core::Map::[]=}{Invariant}("bar", dynVar as{TypeError,ForDynamic} core::int*);
+    #t124.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t124;
   core::List<core::int*>* list91 = block {
     final core::List<core::int*>* #t125 = <core::int*>[];
@@ -1163,7 +1163,7 @@
         final dynamic #t126 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int* #t127 = #t126 as{TypeError} core::int*;
-          #t125.{core::List::add}(#t127);
+          #t125.{core::List::add}{Invariant}(#t127);
         }
       }
     }
@@ -1176,11 +1176,11 @@
         final dynamic #t129 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int* #t130 = #t129 as{TypeError} core::int*;
-          #t128.{core::Set::add}(#t130);
+          #t128.{core::Set::add}{Invariant}(#t130);
         }
       }
     }
-    #t128.{core::Set::add}(null);
+    #t128.{core::Set::add}{Invariant}(null);
   } =>#t128;
   core::Map<core::String*, core::int*>* map91 = block {
     final core::Map<core::String*, core::int*>* #t131 = <core::String*, core::int*>{};
@@ -1191,51 +1191,51 @@
         {
           final core::String* #t133 = #t132.{core::MapEntry::key} as{TypeError} core::String*;
           final core::int* #t134 = #t132.{core::MapEntry::value} as{TypeError} core::int*;
-          #t131.{core::Map::[]=}(#t133, #t134);
+          #t131.{core::Map::[]=}{Invariant}(#t133, #t134);
         }
       }
     }
-    #t131.{core::Map::[]=}("baz", null);
+    #t131.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t131;
   core::List<core::int*>* list100 = block {
     final core::List<core::int*>* #t135 = <core::int*>[];
     if(dynVar as{TypeError,ForDynamic} core::bool*)
-      #t135.{core::List::add}(42);
+      #t135.{core::List::add}{Invariant}(42);
   } =>#t135;
   core::Set<core::int*>* set100 = block {
     final core::Set<core::int*>* #t136 = new col::_CompactLinkedHashSet::•<core::int*>();
     if(dynVar as{TypeError,ForDynamic} core::bool*)
-      #t136.{core::Set::add}(42);
+      #t136.{core::Set::add}{Invariant}(42);
   } =>#t136;
   core::Map<core::int*, core::int*>* map100 = block {
     final core::Map<core::int*, core::int*>* #t137 = <core::int*, core::int*>{};
     if(dynVar as{TypeError,ForDynamic} core::bool*)
-      #t137.{core::Map::[]=}(42, 42);
+      #t137.{core::Map::[]=}{Invariant}(42, 42);
   } =>#t137;
 }
 static method testIfElementErrors(core::Map<core::int*, core::int*>* map) → dynamic {
   block {
     final core::List<core::int*>* #t138 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t138.{core::List::add}(let final<BottomType> #t139 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:87:28: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+      #t138.{core::List::add}{Invariant}(let final<BottomType> #t139 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:87:28: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int>[if (oracle(\"foo\")) \"bar\"];
                            ^" in "bar" as{TypeError} core::int*);
   } =>#t138;
   block {
     final core::Set<core::int*>* #t140 = new col::_CompactLinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t140.{core::Set::add}(let final<BottomType> #t141 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:88:28: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+      #t140.{core::Set::add}{Invariant}(let final<BottomType> #t141 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:88:28: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int>{if (oracle(\"foo\")) \"bar\", null};
                            ^" in "bar" as{TypeError} core::int*);
-    #t140.{core::Set::add}(null);
+    #t140.{core::Set::add}{Invariant}(null);
   } =>#t140;
   block {
     final core::Map<core::String*, core::int*>* #t142 = <core::String*, core::int*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t142.{core::Map::[]=}("bar", let final<BottomType> #t143 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:89:43: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+      #t142.{core::Map::[]=}{Invariant}("bar", let final<BottomType> #t143 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:89:43: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <String, int>{if (oracle(\"foo\")) \"bar\": \"bar\", \"baz\": null};
                                           ^" in "bar" as{TypeError} core::int*);
-    #t142.{core::Map::[]=}("baz", null);
+    #t142.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t142;
   block {
     final core::List<core::int*>* #t144 = <core::int*>[];
@@ -1245,7 +1245,7 @@
                                ^" in "bar" as{TypeError} core::int*].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t146 = :sync-for-iterator.{core::Iterator::current};
-        #t144.{core::List::add}(#t146);
+        #t144.{core::List::add}{Invariant}(#t146);
       }
     }
   } =>#t144;
@@ -1257,10 +1257,10 @@
                                ^" in "bar" as{TypeError} core::int*].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t149 = :sync-for-iterator.{core::Iterator::current};
-        #t147.{core::Set::add}(#t149);
+        #t147.{core::Set::add}{Invariant}(#t149);
       }
     }
-    #t147.{core::Set::add}(null);
+    #t147.{core::Set::add}{Invariant}(null);
   } =>#t147;
   block {
     final core::Map<core::String*, core::int*>* #t150 = <core::String*, core::int*>{};
@@ -1270,15 +1270,15 @@
                                               ^" in "bar" as{TypeError} core::int*}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::int*>* #t152 = :sync-for-iterator.{core::Iterator::current};
-        #t150.{core::Map::[]=}(#t152.{core::MapEntry::key}, #t152.{core::MapEntry::value});
+        #t150.{core::Map::[]=}{Invariant}(#t152.{core::MapEntry::key}, #t152.{core::MapEntry::value});
       }
     }
-    #t150.{core::Map::[]=}("baz", null);
+    #t150.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t150;
   block {
     final core::List<core::int*>* #t153 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t153.{core::List::add}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:93:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t153.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:93:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>[if (oracle(\"foo\")) ...map];
                               ^");
@@ -1286,11 +1286,11 @@
   block {
     final core::Set<core::int*>* #t154 = new col::_CompactLinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t154.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:94:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t154.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:94:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>{if (oracle(\"foo\")) ...map, null};
                               ^");
-    #t154.{core::Set::add}(null);
+    #t154.{core::Set::add}{Invariant}(null);
   } =>#t154;
   <core::String*, core::int*>{invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:95:39: Error: Unexpected type 'List<String>' of a map spread entry.  Expected 'dynamic' or a Map.
  - 'List' is from 'dart:core'.
@@ -1302,58 +1302,58 @@
   block {
     final core::List<core::String*>* #t155 = <core::String*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t155.{core::List::add}(let final<BottomType> #t156 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:96:31: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+      #t155.{core::List::add}{Invariant}(let final<BottomType> #t156 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:96:31: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   <String>[if (oracle(\"foo\")) 42 else 3.14];
                               ^" in 42 as{TypeError} core::String*);
     else
-      #t155.{core::List::add}(let final<BottomType> #t157 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:96:39: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
+      #t155.{core::List::add}{Invariant}(let final<BottomType> #t157 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:96:39: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
   <String>[if (oracle(\"foo\")) 42 else 3.14];
                                       ^" in 3.14 as{TypeError} core::String*);
   } =>#t155;
   block {
     final core::Set<core::String*>* #t158 = new col::_CompactLinkedHashSet::•<core::String*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t158.{core::Set::add}(let final<BottomType> #t159 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:97:31: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+      #t158.{core::Set::add}{Invariant}(let final<BottomType> #t159 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:97:31: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   <String>{if (oracle(\"foo\")) 42 else 3.14, null};
                               ^" in 42 as{TypeError} core::String*);
     else
-      #t158.{core::Set::add}(let final<BottomType> #t160 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:97:39: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
+      #t158.{core::Set::add}{Invariant}(let final<BottomType> #t160 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:97:39: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
   <String>{if (oracle(\"foo\")) 42 else 3.14, null};
                                       ^" in 3.14 as{TypeError} core::String*);
-    #t158.{core::Set::add}(null);
+    #t158.{core::Set::add}{Invariant}(null);
   } =>#t158;
   block {
     final core::Map<core::String*, core::String*>* #t161 = <core::String*, core::String*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t161.{core::Map::[]=}("bar", let final<BottomType> #t162 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:98:46: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+      #t161.{core::Map::[]=}{Invariant}("bar", let final<BottomType> #t162 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:98:46: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   <String, String>{if (oracle(\"foo\")) \"bar\": 42 else \"baz\": 3.14, \"baz\": null};
                                              ^" in 42 as{TypeError} core::String*);
     else
-      #t161.{core::Map::[]=}("baz", let final<BottomType> #t163 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:98:61: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
+      #t161.{core::Map::[]=}{Invariant}("baz", let final<BottomType> #t163 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:98:61: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
   <String, String>{if (oracle(\"foo\")) \"bar\": 42 else \"baz\": 3.14, \"baz\": null};
                                                             ^" in 3.14 as{TypeError} core::String*);
-    #t161.{core::Map::[]=}("baz", null);
+    #t161.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t161;
   block {
     final core::List<core::int*>* #t164 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t164.{core::List::add}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:99:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t164.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:99:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>[if (oracle(\"foo\")) ...map else 42];
                               ^");
     else
-      #t164.{core::List::add}(42);
+      #t164.{core::List::add}{Invariant}(42);
   } =>#t164;
   block {
     final core::Set<core::int*>* #t165 = new col::_CompactLinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t165.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:100:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t165.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:100:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>{if (oracle(\"foo\")) ...map else 42, null};
                               ^");
     else
-      #t165.{core::Set::add}(42);
-    #t165.{core::Set::add}(null);
+      #t165.{core::Set::add}{Invariant}(42);
+    #t165.{core::Set::add}{Invariant}(null);
   } =>#t165;
   <core::String*, core::int*>{invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:101:39: Error: Unexpected type 'List<int>' of a map spread entry.  Expected 'dynamic' or a Map.
  - 'List' is from 'dart:core'.
@@ -1365,9 +1365,9 @@
   block {
     final core::List<core::int*>* #t166 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t166.{core::List::add}(42);
+      #t166.{core::List::add}{Invariant}(42);
     else
-      #t166.{core::List::add}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:102:39: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t166.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:102:39: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>[if (oracle(\"foo\")) 42 else ...map];
                                       ^");
@@ -1375,13 +1375,13 @@
   block {
     final core::Set<core::int*>* #t167 = new col::_CompactLinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t167.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:103:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t167.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:103:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>{if (oracle(\"foo\")) ...map else 42, null};
                               ^");
     else
-      #t167.{core::Set::add}(42);
-    #t167.{core::Set::add}(null);
+      #t167.{core::Set::add}{Invariant}(42);
+    #t167.{core::Set::add}{Invariant}(null);
   } =>#t167;
   <core::String*, core::int*>{invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:104:54: Error: Unexpected type 'List<int>' of a map spread entry.  Expected 'dynamic' or a Map.
  - 'List' is from 'dart:core'.
@@ -1413,63 +1413,63 @@
     if(let final<BottomType> #t169 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:112:27: Error: A value of type 'int' can't be assigned to a variable of type 'bool'.
   List<int> list20 = [if (42) 42];
                           ^" in 42 as{TypeError} core::bool*)
-      #t168.{core::List::add}(42);
+      #t168.{core::List::add}{Invariant}(42);
   } =>#t168;
   core::Set<core::int*>* set20 = block {
     final core::Set<core::int*>* #t170 = new col::_CompactLinkedHashSet::•<core::int*>();
     if(let final<BottomType> #t171 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:113:25: Error: A value of type 'int' can't be assigned to a variable of type 'bool'.
   Set<int> set20 = {if (42) 42};
                         ^" in 42 as{TypeError} core::bool*)
-      #t170.{core::Set::add}(42);
+      #t170.{core::Set::add}{Invariant}(42);
   } =>#t170;
   core::Map<core::int*, core::int*>* map30 = block {
     final core::Map<core::int*, core::int*>* #t172 = <core::int*, core::int*>{};
     if(let final<BottomType> #t173 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:114:30: Error: A value of type 'int' can't be assigned to a variable of type 'bool'.
   Map<int, int> map30 = {if (42) 42: 42};
                              ^" in 42 as{TypeError} core::bool*)
-      #t172.{core::Map::[]=}(42, 42);
+      #t172.{core::Map::[]=}{Invariant}(42, 42);
   } =>#t172;
   core::List<core::String*>* list40 = block {
     final core::List<core::String*>* #t174 = <core::String*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t174.{core::List::add}(let final<BottomType> #t175 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:115:53: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
+      #t174.{core::List::add}{Invariant}(let final<BottomType> #t175 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:115:53: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
   List<String> list40 = <String>[if (oracle(\"foo\")) true else 42];
                                                     ^" in true as{TypeError} core::String*);
     else
-      #t174.{core::List::add}(let final<BottomType> #t176 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:115:63: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+      #t174.{core::List::add}{Invariant}(let final<BottomType> #t176 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:115:63: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   List<String> list40 = <String>[if (oracle(\"foo\")) true else 42];
                                                               ^" in 42 as{TypeError} core::String*);
   } =>#t174;
   core::Set<core::String*>* set40 = block {
     final core::Set<core::String*>* #t177 = new col::_CompactLinkedHashSet::•<core::String*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t177.{core::Set::add}(let final<BottomType> #t178 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:116:51: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
+      #t177.{core::Set::add}{Invariant}(let final<BottomType> #t178 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:116:51: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
   Set<String> set40 = <String>{if (oracle(\"foo\")) true else 42};
                                                   ^" in true as{TypeError} core::String*);
     else
-      #t177.{core::Set::add}(let final<BottomType> #t179 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:116:61: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+      #t177.{core::Set::add}{Invariant}(let final<BottomType> #t179 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:116:61: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   Set<String> set40 = <String>{if (oracle(\"foo\")) true else 42};
                                                             ^" in 42 as{TypeError} core::String*);
   } =>#t177;
   core::Map<core::String*, core::int*>* map40 = block {
     final core::Map<core::String*, core::int*>* #t180 = <core::String*, core::int*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t180.{core::Map::[]=}(let final<BottomType> #t181 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:117:61: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
+      #t180.{core::Map::[]=}{Invariant}(let final<BottomType> #t181 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:117:61: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
   Map<String, int> map40 = <String, int>{if (oracle(\"foo\")) true: 42 else 42: 42};
                                                             ^" in true as{TypeError} core::String*, 42);
     else
-      #t180.{core::Map::[]=}(let final<BottomType> #t182 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:117:75: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+      #t180.{core::Map::[]=}{Invariant}(let final<BottomType> #t182 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:117:75: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   Map<String, int> map40 = <String, int>{if (oracle(\"foo\")) true: 42 else 42: 42};
                                                                           ^" in 42 as{TypeError} core::String*, 42);
   } =>#t180;
   core::Map<core::int*, core::String*>* map41 = block {
     final core::Map<core::int*, core::String*>* #t183 = <core::int*, core::String*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t183.{core::Map::[]=}(42, let final<BottomType> #t184 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:118:65: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
+      #t183.{core::Map::[]=}{Invariant}(42, let final<BottomType> #t184 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:118:65: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
   Map<int, String> map41 = <int, String>{if (oracle(\"foo\")) 42: true else 42: 42};
                                                                 ^" in true as{TypeError} core::String*);
     else
-      #t183.{core::Map::[]=}(42, let final<BottomType> #t185 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:118:79: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+      #t183.{core::Map::[]=}{Invariant}(42, let final<BottomType> #t185 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:118:79: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   Map<int, String> map41 = <int, String>{if (oracle(\"foo\")) 42: true else 42: 42};
                                                                               ^" in 42 as{TypeError} core::String*);
   } =>#t183;
@@ -1478,53 +1478,53 @@
   core::List<core::int*>* list10 = block {
     final core::List<core::int*>* #t186 = <core::int*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t186.{core::List::add}(42);
+      #t186.{core::List::add}{Invariant}(42);
   } =>#t186;
   core::Set<core::int*>* set10 = block {
     final core::Set<core::int*>* #t187 = new col::_CompactLinkedHashSet::•<core::int*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t187.{core::Set::add}(42);
-    #t187.{core::Set::add}(null);
+      #t187.{core::Set::add}{Invariant}(42);
+    #t187.{core::Set::add}{Invariant}(null);
   } =>#t187;
   core::Map<core::String*, core::int*>* map10 = block {
     final core::Map<core::String*, core::int*>* #t188 = <core::String*, core::int*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t188.{core::Map::[]=}("bar", 42);
-    #t188.{core::Map::[]=}("baz", null);
+      #t188.{core::Map::[]=}{Invariant}("bar", 42);
+    #t188.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t188;
   core::List<dynamic>* list11 = block {
     final core::List<dynamic>* #t189 = <dynamic>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t189.{core::List::add}(dynVar);
+      #t189.{core::List::add}{Invariant}(dynVar);
   } =>#t189;
   core::Set<dynamic>* set11 = block {
     final core::Set<dynamic>* #t190 = new col::_CompactLinkedHashSet::•<dynamic>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t190.{core::Set::add}(dynVar);
-    #t190.{core::Set::add}(null);
+      #t190.{core::Set::add}{Invariant}(dynVar);
+    #t190.{core::Set::add}{Invariant}(null);
   } =>#t190;
   core::Map<core::String*, dynamic>* map11 = block {
     final core::Map<core::String*, dynamic>* #t191 = <core::String*, dynamic>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t191.{core::Map::[]=}("bar", dynVar);
-    #t191.{core::Map::[]=}("baz", null);
+      #t191.{core::Map::[]=}{Invariant}("bar", dynVar);
+    #t191.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t191;
   core::List<core::List<core::int*>*>* list12 = block {
     final core::List<core::List<core::int*>*>* #t192 = <core::List<core::int*>*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t192.{core::List::add}(<core::int*>[42]);
+      #t192.{core::List::add}{Invariant}(<core::int*>[42]);
   } =>#t192;
   core::Set<core::List<core::int*>*>* set12 = block {
     final core::Set<core::List<core::int*>*>* #t193 = new col::_CompactLinkedHashSet::•<core::List<core::int*>*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t193.{core::Set::add}(<core::int*>[42]);
-    #t193.{core::Set::add}(null);
+      #t193.{core::Set::add}{Invariant}(<core::int*>[42]);
+    #t193.{core::Set::add}{Invariant}(null);
   } =>#t193;
   core::Map<core::String*, core::List<core::int*>*>* map12 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t194 = <core::String*, core::List<core::int*>*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t194.{core::Map::[]=}("bar", <core::int*>[42]);
-    #t194.{core::Map::[]=}("baz", null);
+      #t194.{core::Map::[]=}{Invariant}("bar", <core::int*>[42]);
+    #t194.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t194;
   core::List<core::int*>* list20 = block {
     final core::List<core::int*>* #t195 = <core::int*>[];
@@ -1532,7 +1532,7 @@
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[42].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t196 = :sync-for-iterator.{core::Iterator::current};
-        #t195.{core::List::add}(#t196);
+        #t195.{core::List::add}{Invariant}(#t196);
       }
     }
   } =>#t195;
@@ -1542,10 +1542,10 @@
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[42].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t198 = :sync-for-iterator.{core::Iterator::current};
-        #t197.{core::Set::add}(#t198);
+        #t197.{core::Set::add}{Invariant}(#t198);
       }
     }
-    #t197.{core::Set::add}(null);
+    #t197.{core::Set::add}{Invariant}(null);
   } =>#t197;
   core::Map<core::String*, core::int*>* map20 = block {
     final core::Map<core::String*, core::int*>* #t199 = <core::String*, core::int*>{};
@@ -1553,10 +1553,10 @@
       core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = <core::String*, core::int*>{"bar": 42}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::int*>* #t200 = :sync-for-iterator.{core::Iterator::current};
-        #t199.{core::Map::[]=}(#t200.{core::MapEntry::key}, #t200.{core::MapEntry::value});
+        #t199.{core::Map::[]=}{Invariant}(#t200.{core::MapEntry::key}, #t200.{core::MapEntry::value});
       }
     }
-    #t199.{core::Map::[]=}("baz", null);
+    #t199.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t199;
   core::List<dynamic>* list21 = block {
     final core::List<dynamic>* #t201 = <dynamic>[];
@@ -1564,7 +1564,7 @@
       core::Iterator<dynamic>* :sync-for-iterator = <dynamic>[dynVar].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final dynamic #t202 = :sync-for-iterator.{core::Iterator::current};
-        #t201.{core::List::add}(#t202);
+        #t201.{core::List::add}{Invariant}(#t202);
       }
     }
   } =>#t201;
@@ -1574,10 +1574,10 @@
       core::Iterator<dynamic>* :sync-for-iterator = <dynamic>[dynVar].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final dynamic #t204 = :sync-for-iterator.{core::Iterator::current};
-        #t203.{core::Set::add}(#t204);
+        #t203.{core::Set::add}{Invariant}(#t204);
       }
     }
-    #t203.{core::Set::add}(null);
+    #t203.{core::Set::add}{Invariant}(null);
   } =>#t203;
   core::Map<core::String*, dynamic>* map21 = block {
     final core::Map<core::String*, dynamic>* #t205 = <core::String*, dynamic>{};
@@ -1585,10 +1585,10 @@
       core::Iterator<core::MapEntry<core::String*, dynamic>>* :sync-for-iterator = <core::String*, dynamic>{"bar": dynVar}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, dynamic>* #t206 = :sync-for-iterator.{core::Iterator::current};
-        #t205.{core::Map::[]=}(#t206.{core::MapEntry::key}, #t206.{core::MapEntry::value});
+        #t205.{core::Map::[]=}{Invariant}(#t206.{core::MapEntry::key}, #t206.{core::MapEntry::value});
       }
     }
-    #t205.{core::Map::[]=}("baz", null);
+    #t205.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t205;
   core::List<core::List<core::int*>*>* list22 = block {
     final core::List<core::List<core::int*>*>* #t207 = <core::List<core::int*>*>[];
@@ -1596,7 +1596,7 @@
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[42]].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t208 = :sync-for-iterator.{core::Iterator::current};
-        #t207.{core::List::add}(#t208);
+        #t207.{core::List::add}{Invariant}(#t208);
       }
     }
   } =>#t207;
@@ -1606,10 +1606,10 @@
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[42]].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t210 = :sync-for-iterator.{core::Iterator::current};
-        #t209.{core::Set::add}(#t210);
+        #t209.{core::Set::add}{Invariant}(#t210);
       }
     }
-    #t209.{core::Set::add}(null);
+    #t209.{core::Set::add}{Invariant}(null);
   } =>#t209;
   core::Map<core::String*, core::List<core::int*>*>* map22 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t211 = <core::String*, core::List<core::int*>*>{};
@@ -1617,10 +1617,10 @@
       core::Iterator<core::MapEntry<core::String*, core::List<core::int*>*>>* :sync-for-iterator = <core::String*, core::List<core::int*>*>{"bar": <core::int*>[42]}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::List<core::int*>*>* #t212 = :sync-for-iterator.{core::Iterator::current};
-        #t211.{core::Map::[]=}(#t212.{core::MapEntry::key}, #t212.{core::MapEntry::value});
+        #t211.{core::Map::[]=}{Invariant}(#t212.{core::MapEntry::key}, #t212.{core::MapEntry::value});
       }
     }
-    #t211.{core::Map::[]=}("baz", null);
+    #t211.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t211;
   core::List<core::int*>* list30 = block {
     final core::List<core::int*>* #t213 = <core::int*>[];
@@ -1629,7 +1629,7 @@
         core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[42].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::int* #t214 = :sync-for-iterator.{core::Iterator::current};
-          #t213.{core::List::add}(#t214);
+          #t213.{core::List::add}{Invariant}(#t214);
         }
       }
   } =>#t213;
@@ -1640,10 +1640,10 @@
         core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[42].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::int* #t216 = :sync-for-iterator.{core::Iterator::current};
-          #t215.{core::Set::add}(#t216);
+          #t215.{core::Set::add}{Invariant}(#t216);
         }
       }
-    #t215.{core::Set::add}(null);
+    #t215.{core::Set::add}{Invariant}(null);
   } =>#t215;
   core::Map<core::String*, core::int*>* map30 = block {
     final core::Map<core::String*, core::int*>* #t217 = <core::String*, core::int*>{};
@@ -1652,10 +1652,10 @@
         core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = <core::String*, core::int*>{"bar": 42}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::String*, core::int*>* #t218 = :sync-for-iterator.{core::Iterator::current};
-          #t217.{core::Map::[]=}(#t218.{core::MapEntry::key}, #t218.{core::MapEntry::value});
+          #t217.{core::Map::[]=}{Invariant}(#t218.{core::MapEntry::key}, #t218.{core::MapEntry::value});
         }
       }
-    #t217.{core::Map::[]=}("baz", null);
+    #t217.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t217;
   core::List<dynamic>* list31 = block {
     final core::List<dynamic>* #t219 = <dynamic>[];
@@ -1664,7 +1664,7 @@
         core::Iterator<dynamic>* :sync-for-iterator = <dynamic>[dynVar].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final dynamic #t220 = :sync-for-iterator.{core::Iterator::current};
-          #t219.{core::List::add}(#t220);
+          #t219.{core::List::add}{Invariant}(#t220);
         }
       }
   } =>#t219;
@@ -1675,10 +1675,10 @@
         core::Iterator<dynamic>* :sync-for-iterator = <dynamic>[dynVar].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final dynamic #t222 = :sync-for-iterator.{core::Iterator::current};
-          #t221.{core::Set::add}(#t222);
+          #t221.{core::Set::add}{Invariant}(#t222);
         }
       }
-    #t221.{core::Set::add}(null);
+    #t221.{core::Set::add}{Invariant}(null);
   } =>#t221;
   core::Map<core::String*, dynamic>* map31 = block {
     final core::Map<core::String*, dynamic>* #t223 = <core::String*, dynamic>{};
@@ -1687,10 +1687,10 @@
         core::Iterator<core::MapEntry<core::String*, dynamic>>* :sync-for-iterator = <core::String*, dynamic>{"bar": dynVar}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::String*, dynamic>* #t224 = :sync-for-iterator.{core::Iterator::current};
-          #t223.{core::Map::[]=}(#t224.{core::MapEntry::key}, #t224.{core::MapEntry::value});
+          #t223.{core::Map::[]=}{Invariant}(#t224.{core::MapEntry::key}, #t224.{core::MapEntry::value});
         }
       }
-    #t223.{core::Map::[]=}("baz", null);
+    #t223.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t223;
   core::List<core::List<core::int*>*>* list33 = block {
     final core::List<core::List<core::int*>*>* #t225 = <core::List<core::int*>*>[];
@@ -1699,7 +1699,7 @@
         core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[42]].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::List<core::int*>* #t226 = :sync-for-iterator.{core::Iterator::current};
-          #t225.{core::List::add}(#t226);
+          #t225.{core::List::add}{Invariant}(#t226);
         }
       }
   } =>#t225;
@@ -1710,10 +1710,10 @@
         core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[42]].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::List<core::int*>* #t228 = :sync-for-iterator.{core::Iterator::current};
-          #t227.{core::Set::add}(#t228);
+          #t227.{core::Set::add}{Invariant}(#t228);
         }
       }
-    #t227.{core::Set::add}(null);
+    #t227.{core::Set::add}{Invariant}(null);
   } =>#t227;
   core::Map<core::String*, core::List<core::int*>*>* map33 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t229 = <core::String*, core::List<core::int*>*>{};
@@ -1722,10 +1722,10 @@
         core::Iterator<core::MapEntry<core::String*, core::List<core::int*>*>>* :sync-for-iterator = <core::String*, core::List<core::int*>*>{"bar": <core::int*>[42]}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::String*, core::List<core::int*>*>* #t230 = :sync-for-iterator.{core::Iterator::current};
-          #t229.{core::Map::[]=}(#t230.{core::MapEntry::key}, #t230.{core::MapEntry::value});
+          #t229.{core::Map::[]=}{Invariant}(#t230.{core::MapEntry::key}, #t230.{core::MapEntry::value});
         }
       }
-    #t229.{core::Map::[]=}("baz", null);
+    #t229.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t229;
   core::List<core::List<core::int*>*>* list40 = block {
     final core::List<core::List<core::int*>*>* #t231 = <core::List<core::int*>*>[];
@@ -1733,7 +1733,7 @@
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t232 = :sync-for-iterator.{core::Iterator::current};
-        #t231.{core::List::add}(#t232);
+        #t231.{core::List::add}{Invariant}(#t232);
       }
     }
   } =>#t231;
@@ -1743,10 +1743,10 @@
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t234 = :sync-for-iterator.{core::Iterator::current};
-        #t233.{core::Set::add}(#t234);
+        #t233.{core::Set::add}{Invariant}(#t234);
       }
     }
-    #t233.{core::Set::add}(null);
+    #t233.{core::Set::add}{Invariant}(null);
   } =>#t233;
   core::Map<core::String*, core::List<core::int*>*>* map40 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t235 = <core::String*, core::List<core::int*>*>{};
@@ -1754,21 +1754,21 @@
       core::Iterator<core::MapEntry<core::String*, core::List<core::int*>*>>* :sync-for-iterator = <core::String*, core::List<core::int*>*>{"bar": <core::int*>[]}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::List<core::int*>*>* #t236 = :sync-for-iterator.{core::Iterator::current};
-        #t235.{core::Map::[]=}(#t236.{core::MapEntry::key}, #t236.{core::MapEntry::value});
+        #t235.{core::Map::[]=}{Invariant}(#t236.{core::MapEntry::key}, #t236.{core::MapEntry::value});
       }
     }
-    #t235.{core::Map::[]=}("baz", null);
+    #t235.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t235;
   core::List<core::List<core::int*>*>* list41 = block {
     final core::List<core::List<core::int*>*>* #t237 = <core::List<core::int*>*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1)) {
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = ( block {
         final core::Set<core::List<core::int*>*>* #t238 = new col::_CompactLinkedHashSet::•<core::List<core::int*>*>();
-        #t238.{core::Set::add}(<core::int*>[]);
+        #t238.{core::Set::add}{Invariant}(<core::int*>[]);
       } =>#t238).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t239 = :sync-for-iterator.{core::Iterator::current};
-        #t237.{core::List::add}(#t239);
+        #t237.{core::List::add}{Invariant}(#t239);
       }
     }
   } =>#t237;
@@ -1777,14 +1777,14 @@
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1)) {
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = ( block {
         final core::Set<core::List<core::int*>*>* #t241 = new col::_CompactLinkedHashSet::•<core::List<core::int*>*>();
-        #t241.{core::Set::add}(<core::int*>[]);
+        #t241.{core::Set::add}{Invariant}(<core::int*>[]);
       } =>#t241).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t242 = :sync-for-iterator.{core::Iterator::current};
-        #t240.{core::Set::add}(#t242);
+        #t240.{core::Set::add}{Invariant}(#t242);
       }
     }
-    #t240.{core::Set::add}(null);
+    #t240.{core::Set::add}{Invariant}(null);
   } =>#t240;
   core::List<core::List<core::int*>*>* list42 = block {
     final core::List<core::List<core::int*>*>* #t243 = <core::List<core::int*>*>[];
@@ -1793,7 +1793,7 @@
         core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::List<core::int*>* #t244 = :sync-for-iterator.{core::Iterator::current};
-          #t243.{core::List::add}(#t244);
+          #t243.{core::List::add}{Invariant}(#t244);
         }
       }
   } =>#t243;
@@ -1804,10 +1804,10 @@
         core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::List<core::int*>* #t246 = :sync-for-iterator.{core::Iterator::current};
-          #t245.{core::Set::add}(#t246);
+          #t245.{core::Set::add}{Invariant}(#t246);
         }
       }
-    #t245.{core::Set::add}(null);
+    #t245.{core::Set::add}{Invariant}(null);
   } =>#t245;
   core::Map<core::String*, core::List<core::int*>*>* map42 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t247 = <core::String*, core::List<core::int*>*>{};
@@ -1816,10 +1816,10 @@
         core::Iterator<core::MapEntry<core::String*, core::List<core::int*>*>>* :sync-for-iterator = <core::String*, core::List<core::int*>*>{"bar": <core::int*>[]}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::String*, core::List<core::int*>*>* #t248 = :sync-for-iterator.{core::Iterator::current};
-          #t247.{core::Map::[]=}(#t248.{core::MapEntry::key}, #t248.{core::MapEntry::value});
+          #t247.{core::Map::[]=}{Invariant}(#t248.{core::MapEntry::key}, #t248.{core::MapEntry::value});
         }
       }
-    #t247.{core::Map::[]=}("baz", null);
+    #t247.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t247;
   core::List<core::int*>* list50 = block {
     final core::List<core::int*>* #t249 = <core::int*>[];
@@ -1827,7 +1827,7 @@
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t250 = :sync-for-iterator.{core::Iterator::current};
-        #t249.{core::List::add}(#t250);
+        #t249.{core::List::add}{Invariant}(#t250);
       }
     }
   } =>#t249;
@@ -1837,10 +1837,10 @@
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t252 = :sync-for-iterator.{core::Iterator::current};
-        #t251.{core::Set::add}(#t252);
+        #t251.{core::Set::add}{Invariant}(#t252);
       }
     }
-    #t251.{core::Set::add}(null);
+    #t251.{core::Set::add}{Invariant}(null);
   } =>#t251;
   core::Map<core::String*, core::int*>* map50 = block {
     final core::Map<core::String*, core::int*>* #t253 = <core::String*, core::int*>{};
@@ -1848,10 +1848,10 @@
       core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = <core::String*, core::int*>{}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::int*>* #t254 = :sync-for-iterator.{core::Iterator::current};
-        #t253.{core::Map::[]=}(#t254.{core::MapEntry::key}, #t254.{core::MapEntry::value});
+        #t253.{core::Map::[]=}{Invariant}(#t254.{core::MapEntry::key}, #t254.{core::MapEntry::value});
       }
     }
-    #t253.{core::Map::[]=}("baz", null);
+    #t253.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t253;
   core::List<core::int*>* list51 = block {
     final core::List<core::int*>* #t255 = <core::int*>[];
@@ -1861,7 +1861,7 @@
       } =>#t256).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t257 = :sync-for-iterator.{core::Iterator::current};
-        #t255.{core::List::add}(#t257);
+        #t255.{core::List::add}{Invariant}(#t257);
       }
     }
   } =>#t255;
@@ -1873,10 +1873,10 @@
       } =>#t259).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t260 = :sync-for-iterator.{core::Iterator::current};
-        #t258.{core::Set::add}(#t260);
+        #t258.{core::Set::add}{Invariant}(#t260);
       }
     }
-    #t258.{core::Set::add}(null);
+    #t258.{core::Set::add}{Invariant}(null);
   } =>#t258;
   core::List<core::int*>* list52 = block {
     final core::List<core::int*>* #t261 = <core::int*>[];
@@ -1885,7 +1885,7 @@
         core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::int* #t262 = :sync-for-iterator.{core::Iterator::current};
-          #t261.{core::List::add}(#t262);
+          #t261.{core::List::add}{Invariant}(#t262);
         }
       }
   } =>#t261;
@@ -1896,10 +1896,10 @@
         core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::int* #t264 = :sync-for-iterator.{core::Iterator::current};
-          #t263.{core::Set::add}(#t264);
+          #t263.{core::Set::add}{Invariant}(#t264);
         }
       }
-    #t263.{core::Set::add}(null);
+    #t263.{core::Set::add}{Invariant}(null);
   } =>#t263;
   core::List<core::List<core::int*>*>* list60 = block {
     final core::List<core::List<core::int*>*>* #t265 = <core::List<core::int*>*>[];
@@ -1907,7 +1907,7 @@
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t266 = :sync-for-iterator.{core::Iterator::current};
-        #t265.{core::List::add}(#t266);
+        #t265.{core::List::add}{Invariant}(#t266);
       }
     }
   } =>#t265;
@@ -1917,10 +1917,10 @@
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t268 = :sync-for-iterator.{core::Iterator::current};
-        #t267.{core::Set::add}(#t268);
+        #t267.{core::Set::add}{Invariant}(#t268);
       }
     }
-    #t267.{core::Set::add}(null);
+    #t267.{core::Set::add}{Invariant}(null);
   } =>#t267;
   core::Map<core::String*, core::List<core::int*>*>* map60 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t269 = <core::String*, core::List<core::int*>*>{};
@@ -1928,10 +1928,10 @@
       core::Iterator<core::MapEntry<core::String*, core::List<core::int*>*>>* :sync-for-iterator = <core::String*, core::List<core::int*>*>{"bar": <core::int*>[]}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::List<core::int*>*>* #t270 = :sync-for-iterator.{core::Iterator::current};
-        #t269.{core::Map::[]=}(#t270.{core::MapEntry::key}, #t270.{core::MapEntry::value});
+        #t269.{core::Map::[]=}{Invariant}(#t270.{core::MapEntry::key}, #t270.{core::MapEntry::value});
       }
     }
-    #t269.{core::Map::[]=}("baz", null);
+    #t269.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t269;
   core::List<core::List<core::int*>*>* list61 = block {
     final core::List<core::List<core::int*>*>* #t271 = <core::List<core::int*>*>[];
@@ -1940,7 +1940,7 @@
         core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::List<core::int*>* #t272 = :sync-for-iterator.{core::Iterator::current};
-          #t271.{core::List::add}(#t272);
+          #t271.{core::List::add}{Invariant}(#t272);
         }
       }
   } =>#t271;
@@ -1951,10 +1951,10 @@
         core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::List<core::int*>* #t274 = :sync-for-iterator.{core::Iterator::current};
-          #t273.{core::Set::add}(#t274);
+          #t273.{core::Set::add}{Invariant}(#t274);
         }
       }
-    #t273.{core::Set::add}(null);
+    #t273.{core::Set::add}{Invariant}(null);
   } =>#t273;
   core::Map<core::String*, core::List<core::int*>*>* map61 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t275 = <core::String*, core::List<core::int*>*>{};
@@ -1963,73 +1963,73 @@
         core::Iterator<core::MapEntry<core::String*, core::List<core::int*>*>>* :sync-for-iterator = <core::String*, core::List<core::int*>*>{"bar": <core::int*>[]}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::String*, core::List<core::int*>*>* #t276 = :sync-for-iterator.{core::Iterator::current};
-          #t275.{core::Map::[]=}(#t276.{core::MapEntry::key}, #t276.{core::MapEntry::value});
+          #t275.{core::Map::[]=}{Invariant}(#t276.{core::MapEntry::key}, #t276.{core::MapEntry::value});
         }
       }
-    #t275.{core::Map::[]=}("baz", null);
+    #t275.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t275;
   core::List<core::List<core::int*>*>* list70 = block {
     final core::List<core::List<core::int*>*>* #t277 = <core::List<core::int*>*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t277.{core::List::add}(<core::int*>[]);
+      #t277.{core::List::add}{Invariant}(<core::int*>[]);
   } =>#t277;
   core::Set<core::List<core::int*>*>* set70 = block {
     final core::Set<core::List<core::int*>*>* #t278 = new col::_CompactLinkedHashSet::•<core::List<core::int*>*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t278.{core::Set::add}(<core::int*>[]);
-    #t278.{core::Set::add}(null);
+      #t278.{core::Set::add}{Invariant}(<core::int*>[]);
+    #t278.{core::Set::add}{Invariant}(null);
   } =>#t278;
   core::Map<core::String*, core::List<core::int*>*>* map70 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t279 = <core::String*, core::List<core::int*>*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t279.{core::Map::[]=}("bar", <core::int*>[]);
-    #t279.{core::Map::[]=}("baz", null);
+      #t279.{core::Map::[]=}{Invariant}("bar", <core::int*>[]);
+    #t279.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t279;
   core::List<core::List<core::int*>*>* list71 = block {
     final core::List<core::List<core::int*>*>* #t280 = <core::List<core::int*>*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t280.{core::List::add}(<core::int*>[]);
+        #t280.{core::List::add}{Invariant}(<core::int*>[]);
   } =>#t280;
   core::Set<core::List<core::int*>*>* set71 = block {
     final core::Set<core::List<core::int*>*>* #t281 = new col::_CompactLinkedHashSet::•<core::List<core::int*>*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t281.{core::Set::add}(<core::int*>[]);
-    #t281.{core::Set::add}(null);
+        #t281.{core::Set::add}{Invariant}(<core::int*>[]);
+    #t281.{core::Set::add}{Invariant}(null);
   } =>#t281;
   core::Map<core::String*, core::List<core::int*>*>* map71 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t282 = <core::String*, core::List<core::int*>*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t282.{core::Map::[]=}("bar", <core::int*>[]);
-    #t282.{core::Map::[]=}("baz", null);
+        #t282.{core::Map::[]=}{Invariant}("bar", <core::int*>[]);
+    #t282.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t282;
   core::List<core::num*>* list80 = block {
     final core::List<core::num*>* #t283 = <core::num*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t283.{core::List::add}(42);
+        #t283.{core::List::add}{Invariant}(42);
       else
-        #t283.{core::List::add}(3.14);
+        #t283.{core::List::add}{Invariant}(3.14);
   } =>#t283;
   core::Set<core::num*>* set80 = block {
     final core::Set<core::num*>* #t284 = new col::_CompactLinkedHashSet::•<core::num*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t284.{core::Set::add}(42);
+        #t284.{core::Set::add}{Invariant}(42);
       else
-        #t284.{core::Set::add}(3.14);
-    #t284.{core::Set::add}(null);
+        #t284.{core::Set::add}{Invariant}(3.14);
+    #t284.{core::Set::add}{Invariant}(null);
   } =>#t284;
   core::Map<core::String*, core::num*>* map80 = block {
     final core::Map<core::String*, core::num*>* #t285 = <core::String*, core::num*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t285.{core::Map::[]=}("bar", 42);
+        #t285.{core::Map::[]=}{Invariant}("bar", 42);
       else
-        #t285.{core::Map::[]=}("bar", 3.14);
-    #t285.{core::Map::[]=}("baz", null);
+        #t285.{core::Map::[]=}{Invariant}("bar", 3.14);
+    #t285.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t285;
   core::List<core::num*>* list81 = block {
     final core::List<core::num*>* #t286 = <core::num*>[];
@@ -2038,14 +2038,14 @@
         core::Iterator<core::int*>* :sync-for-iterator = listInt.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::num* #t287 = :sync-for-iterator.{core::Iterator::current};
-          #t286.{core::List::add}(#t287);
+          #t286.{core::List::add}{Invariant}(#t287);
         }
       }
       else {
         core::Iterator<core::double*>* :sync-for-iterator = listDouble.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::num* #t288 = :sync-for-iterator.{core::Iterator::current};
-          #t286.{core::List::add}(#t288);
+          #t286.{core::List::add}{Invariant}(#t288);
         }
       }
   } =>#t286;
@@ -2056,17 +2056,17 @@
         core::Iterator<core::int*>* :sync-for-iterator = listInt.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::num* #t290 = :sync-for-iterator.{core::Iterator::current};
-          #t289.{core::Set::add}(#t290);
+          #t289.{core::Set::add}{Invariant}(#t290);
         }
       }
       else {
         core::Iterator<core::double*>* :sync-for-iterator = listDouble.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::num* #t291 = :sync-for-iterator.{core::Iterator::current};
-          #t289.{core::Set::add}(#t291);
+          #t289.{core::Set::add}{Invariant}(#t291);
         }
       }
-    #t289.{core::Set::add}(null);
+    #t289.{core::Set::add}{Invariant}(null);
   } =>#t289;
   core::Map<core::String*, core::num*>* map81 = block {
     final core::Map<core::String*, core::num*>* #t292 = <core::String*, core::num*>{};
@@ -2075,17 +2075,17 @@
         core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = mapStringInt.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::String*, core::num*>* #t293 = :sync-for-iterator.{core::Iterator::current};
-          #t292.{core::Map::[]=}(#t293.{core::MapEntry::key}, #t293.{core::MapEntry::value});
+          #t292.{core::Map::[]=}{Invariant}(#t293.{core::MapEntry::key}, #t293.{core::MapEntry::value});
         }
       }
       else {
         core::Iterator<core::MapEntry<core::String*, core::double*>>* :sync-for-iterator = mapStringDouble.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::String*, core::num*>* #t294 = :sync-for-iterator.{core::Iterator::current};
-          #t292.{core::Map::[]=}(#t294.{core::MapEntry::key}, #t294.{core::MapEntry::value});
+          #t292.{core::Map::[]=}{Invariant}(#t294.{core::MapEntry::key}, #t294.{core::MapEntry::value});
         }
       }
-    #t292.{core::Map::[]=}("baz", null);
+    #t292.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t292;
   core::List<dynamic>* list82 = block {
     final core::List<dynamic>* #t295 = <dynamic>[];
@@ -2094,14 +2094,14 @@
         core::Iterator<core::int*>* :sync-for-iterator = listInt.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final dynamic #t296 = :sync-for-iterator.{core::Iterator::current};
-          #t295.{core::List::add}(#t296);
+          #t295.{core::List::add}{Invariant}(#t296);
         }
       }
       else {
         core::Iterator<dynamic>* :sync-for-iterator = (dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*).{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final dynamic #t297 = :sync-for-iterator.{core::Iterator::current};
-          #t295.{core::List::add}(#t297);
+          #t295.{core::List::add}{Invariant}(#t297);
         }
       }
   } =>#t295;
@@ -2112,17 +2112,17 @@
         core::Iterator<core::int*>* :sync-for-iterator = listInt.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final dynamic #t299 = :sync-for-iterator.{core::Iterator::current};
-          #t298.{core::Set::add}(#t299);
+          #t298.{core::Set::add}{Invariant}(#t299);
         }
       }
       else {
         core::Iterator<dynamic>* :sync-for-iterator = (dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*).{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final dynamic #t300 = :sync-for-iterator.{core::Iterator::current};
-          #t298.{core::Set::add}(#t300);
+          #t298.{core::Set::add}{Invariant}(#t300);
         }
       }
-    #t298.{core::Set::add}(null);
+    #t298.{core::Set::add}{Invariant}(null);
   } =>#t298;
   core::Map<dynamic, dynamic>* map82 = block {
     final core::Map<dynamic, dynamic>* #t301 = <dynamic, dynamic>{};
@@ -2131,28 +2131,28 @@
         core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = mapStringInt.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<dynamic, dynamic>* #t302 = :sync-for-iterator.{core::Iterator::current};
-          #t301.{core::Map::[]=}(#t302.{core::MapEntry::key}, #t302.{core::MapEntry::value});
+          #t301.{core::Map::[]=}{Invariant}(#t302.{core::MapEntry::key}, #t302.{core::MapEntry::value});
         }
       }
       else {
         core::Iterator<core::MapEntry<dynamic, dynamic>>* :sync-for-iterator = (dynVar as{TypeError,ForDynamic} core::Map<dynamic, dynamic>*).{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<dynamic, dynamic>* #t303 = :sync-for-iterator.{core::Iterator::current};
-          #t301.{core::Map::[]=}(#t303.{core::MapEntry::key}, #t303.{core::MapEntry::value});
+          #t301.{core::Map::[]=}{Invariant}(#t303.{core::MapEntry::key}, #t303.{core::MapEntry::value});
         }
       }
-    #t301.{core::Map::[]=}("baz", null);
+    #t301.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t301;
   core::List<core::num*>* list83 = block {
     final core::List<core::num*>* #t304 = <core::num*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t304.{core::List::add}(42);
+        #t304.{core::List::add}{Invariant}(42);
       else {
         core::Iterator<core::double*>* :sync-for-iterator = listDouble.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::num* #t305 = :sync-for-iterator.{core::Iterator::current};
-          #t304.{core::List::add}(#t305);
+          #t304.{core::List::add}{Invariant}(#t305);
         }
       }
   } =>#t304;
@@ -2163,12 +2163,12 @@
         core::Iterator<core::int*>* :sync-for-iterator = listInt.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::num* #t307 = :sync-for-iterator.{core::Iterator::current};
-          #t306.{core::Set::add}(#t307);
+          #t306.{core::Set::add}{Invariant}(#t307);
         }
       }
       else
-        #t306.{core::Set::add}(3.14);
-    #t306.{core::Set::add}(null);
+        #t306.{core::Set::add}{Invariant}(3.14);
+    #t306.{core::Set::add}{Invariant}(null);
   } =>#t306;
   core::Map<core::String*, core::num*>* map83 = block {
     final core::Map<core::String*, core::num*>* #t308 = <core::String*, core::num*>{};
@@ -2177,29 +2177,29 @@
         core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = mapStringInt.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::String*, core::num*>* #t309 = :sync-for-iterator.{core::Iterator::current};
-          #t308.{core::Map::[]=}(#t309.{core::MapEntry::key}, #t309.{core::MapEntry::value});
+          #t308.{core::Map::[]=}{Invariant}(#t309.{core::MapEntry::key}, #t309.{core::MapEntry::value});
         }
       }
       else
-        #t308.{core::Map::[]=}("bar", 3.14);
-    #t308.{core::Map::[]=}("baz", null);
+        #t308.{core::Map::[]=}{Invariant}("bar", 3.14);
+    #t308.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t308;
   core::List<core::int*>* list90 = block {
     final core::List<core::int*>* #t310 = <core::int*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t310.{core::List::add}(dynVar as{TypeError,ForDynamic} core::int*);
+      #t310.{core::List::add}{Invariant}(dynVar as{TypeError,ForDynamic} core::int*);
   } =>#t310;
   core::Set<core::int*>* set90 = block {
     final core::Set<core::int*>* #t311 = new col::_CompactLinkedHashSet::•<core::int*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t311.{core::Set::add}(dynVar as{TypeError,ForDynamic} core::int*);
-    #t311.{core::Set::add}(null);
+      #t311.{core::Set::add}{Invariant}(dynVar as{TypeError,ForDynamic} core::int*);
+    #t311.{core::Set::add}{Invariant}(null);
   } =>#t311;
   core::Map<core::String*, core::int*>* map90 = block {
     final core::Map<core::String*, core::int*>* #t312 = <core::String*, core::int*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t312.{core::Map::[]=}("bar", dynVar as{TypeError,ForDynamic} core::int*);
-    #t312.{core::Map::[]=}("baz", null);
+      #t312.{core::Map::[]=}{Invariant}("bar", dynVar as{TypeError,ForDynamic} core::int*);
+    #t312.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t312;
   core::List<core::int*>* list91 = block {
     final core::List<core::int*>* #t313 = <core::int*>[];
@@ -2209,7 +2209,7 @@
         final dynamic #t314 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int* #t315 = #t314 as{TypeError} core::int*;
-          #t313.{core::List::add}(#t315);
+          #t313.{core::List::add}{Invariant}(#t315);
         }
       }
     }
@@ -2222,11 +2222,11 @@
         final dynamic #t317 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int* #t318 = #t317 as{TypeError} core::int*;
-          #t316.{core::Set::add}(#t318);
+          #t316.{core::Set::add}{Invariant}(#t318);
         }
       }
     }
-    #t316.{core::Set::add}(null);
+    #t316.{core::Set::add}{Invariant}(null);
   } =>#t316;
   core::Map<core::String*, core::int*>* map91 = block {
     final core::Map<core::String*, core::int*>* #t319 = <core::String*, core::int*>{};
@@ -2237,26 +2237,26 @@
         {
           final core::String* #t321 = #t320.{core::MapEntry::key} as{TypeError} core::String*;
           final core::int* #t322 = #t320.{core::MapEntry::value} as{TypeError} core::int*;
-          #t319.{core::Map::[]=}(#t321, #t322);
+          #t319.{core::Map::[]=}{Invariant}(#t321, #t322);
         }
       }
     }
-    #t319.{core::Map::[]=}("baz", null);
+    #t319.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t319;
   core::List<core::int*>* list100 = block {
     final core::List<core::int*>* #t323 = <core::int*>[];
     for (final core::int* #t324 = index = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; index = index.{core::num::+}(1))
-      #t323.{core::List::add}(42);
+      #t323.{core::List::add}{Invariant}(42);
   } =>#t323;
   core::Set<core::int*>* set100 = block {
     final core::Set<core::int*>* #t325 = new col::_CompactLinkedHashSet::•<core::int*>();
     for (final core::int* #t326 = index = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; index = index.{core::num::+}(1))
-      #t325.{core::Set::add}(42);
+      #t325.{core::Set::add}{Invariant}(42);
   } =>#t325;
   core::Map<core::String*, core::int*>* map100 = block {
     final core::Map<core::String*, core::int*>* #t327 = <core::String*, core::int*>{};
     for (final core::int* #t328 = index = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; index = index.{core::num::+}(1))
-      #t327.{core::Map::[]=}("bar", 42);
+      #t327.{core::Map::[]=}{Invariant}("bar", 42);
   } =>#t327;
   core::List<core::int*>* list110 = block {
     final core::List<core::int*>* #t329 = <core::int*>[];
@@ -2264,7 +2264,7 @@
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[1, 2, 3].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         core::int* i = :sync-for-iterator.{core::Iterator::current};
-        #t329.{core::List::add}(i);
+        #t329.{core::List::add}{Invariant}(i);
       }
     }
   } =>#t329;
@@ -2274,10 +2274,10 @@
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[1, 2, 3].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         core::int* i = :sync-for-iterator.{core::Iterator::current};
-        #t330.{core::Set::add}(i);
+        #t330.{core::Set::add}{Invariant}(i);
       }
     }
-    #t330.{core::Set::add}(null);
+    #t330.{core::Set::add}{Invariant}(null);
   } =>#t330;
   core::Map<core::String*, core::int*>* map110 = block {
     final core::Map<core::String*, core::int*>* #t331 = <core::String*, core::int*>{};
@@ -2285,10 +2285,10 @@
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[1, 2, 3].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         core::int* i = :sync-for-iterator.{core::Iterator::current};
-        #t331.{core::Map::[]=}("bar", i);
+        #t331.{core::Map::[]=}{Invariant}("bar", i);
       }
     }
-    #t331.{core::Map::[]=}("baz", null);
+    #t331.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t331;
   core::List<core::int*>* list120 = block {
     final core::List<core::int*>* #t332 = <core::int*>[];
@@ -2296,7 +2296,7 @@
       core::Iterator<dynamic>* :sync-for-iterator = (dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         dynamic i = :sync-for-iterator.{core::Iterator::current};
-        #t332.{core::List::add}(i as{TypeError,ForDynamic} core::int*);
+        #t332.{core::List::add}{Invariant}(i as{TypeError,ForDynamic} core::int*);
       }
     }
   } =>#t332;
@@ -2306,10 +2306,10 @@
       core::Iterator<dynamic>* :sync-for-iterator = (dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         dynamic i = :sync-for-iterator.{core::Iterator::current};
-        #t333.{core::Set::add}(i as{TypeError,ForDynamic} core::int*);
+        #t333.{core::Set::add}{Invariant}(i as{TypeError,ForDynamic} core::int*);
       }
     }
-    #t333.{core::Set::add}(null);
+    #t333.{core::Set::add}{Invariant}(null);
   } =>#t333;
   core::Map<core::String*, core::int*>* map120 = block {
     final core::Map<core::String*, core::int*>* #t334 = <core::String*, core::int*>{};
@@ -2317,25 +2317,25 @@
       core::Iterator<dynamic>* :sync-for-iterator = (dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         dynamic i = :sync-for-iterator.{core::Iterator::current};
-        #t334.{core::Map::[]=}("bar", i as{TypeError,ForDynamic} core::int*);
+        #t334.{core::Map::[]=}{Invariant}("bar", i as{TypeError,ForDynamic} core::int*);
       }
     }
-    #t334.{core::Map::[]=}("baz", null);
+    #t334.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t334;
   core::List<core::int*>* list130 = block {
     final core::List<core::int*>* #t335 = <core::int*>[];
     for (core::int* i = 1; i.{core::num::<}(2); i = i.{core::num::+}(1))
-      #t335.{core::List::add}(i);
+      #t335.{core::List::add}{Invariant}(i);
   } =>#t335;
   core::Set<core::int*>* set130 = block {
     final core::Set<core::int*>* #t336 = new col::_CompactLinkedHashSet::•<core::int*>();
     for (core::int* i = 1; i.{core::num::<}(2); i = i.{core::num::+}(1))
-      #t336.{core::Set::add}(i);
+      #t336.{core::Set::add}{Invariant}(i);
   } =>#t336;
   core::Map<core::int*, core::int*>* map130 = block {
     final core::Map<core::int*, core::int*>* #t337 = <core::int*, core::int*>{};
     for (core::int* i = 1; i.{core::num::<}(2); i = i.{core::num::+}(1))
-      #t337.{core::Map::[]=}(i, i);
+      #t337.{core::Map::[]=}{Invariant}(i, i);
   } =>#t337;
 }
 static method testForElementErrors(core::Map<core::int*, core::int*>* map, core::List<core::int*>* list) → dynamic /* originally async */ {
@@ -2358,27 +2358,27 @@
         block {
           final core::List<core::int*>* #t338 = <core::int*>[];
           for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-            #t338.{core::List::add}(let final<BottomType> #t339 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:210:45: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+            #t338.{core::List::add}{Invariant}(let final<BottomType> #t339 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:210:45: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int>[for (int i = 0; oracle(\"foo\"); i++) \"bar\"];
                                             ^" in "bar" as{TypeError} core::int*);
         } =>#t338;
         block {
           final core::Set<core::int*>* #t340 = new col::_CompactLinkedHashSet::•<core::int*>();
           for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-            #t340.{core::Set::add}(let final<BottomType> #t341 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:211:45: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+            #t340.{core::Set::add}{Invariant}(let final<BottomType> #t341 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:211:45: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int>{for (int i = 0; oracle(\"foo\"); i++) \"bar\", null};
                                             ^" in "bar" as{TypeError} core::int*);
-          #t340.{core::Set::add}(null);
+          #t340.{core::Set::add}{Invariant}(null);
         } =>#t340;
         block {
           final core::Map<core::int*, core::int*>* #t342 = <core::int*, core::int*>{};
           for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-            #t342.{core::Map::[]=}(let final<BottomType> #t343 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:212:50: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+            #t342.{core::Map::[]=}{Invariant}(let final<BottomType> #t343 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:212:50: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int, int>{for (int i = 0; oracle(\"foo\"); i++) \"bar\": \"bar\", \"baz\": null};
                                                  ^" in "bar" as{TypeError} core::int*, let final<BottomType> #t344 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:212:57: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int, int>{for (int i = 0; oracle(\"foo\"); i++) \"bar\": \"bar\", \"baz\": null};
                                                         ^" in "bar" as{TypeError} core::int*);
-          #t342.{core::Map::[]=}(let final<BottomType> #t345 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:212:64: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+          #t342.{core::Map::[]=}{Invariant}(let final<BottomType> #t345 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:212:64: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int, int>{for (int i = 0; oracle(\"foo\"); i++) \"bar\": \"bar\", \"baz\": null};
                                                                ^" in "baz" as{TypeError} core::int*, null);
         } =>#t342;
@@ -2390,7 +2390,7 @@
                                                 ^" in "bar" as{TypeError} core::int*].{core::Iterable::iterator};
             for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
               final core::int* #t348 = :sync-for-iterator.{core::Iterator::current};
-              #t346.{core::List::add}(#t348);
+              #t346.{core::List::add}{Invariant}(#t348);
             }
           }
         } =>#t346;
@@ -2402,10 +2402,10 @@
                                                 ^" in "bar" as{TypeError} core::int*].{core::Iterable::iterator};
             for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
               final core::int* #t351 = :sync-for-iterator.{core::Iterator::current};
-              #t349.{core::Set::add}(#t351);
+              #t349.{core::Set::add}{Invariant}(#t351);
             }
           }
-          #t349.{core::Set::add}(null);
+          #t349.{core::Set::add}{Invariant}(null);
         } =>#t349;
         block {
           final core::Map<core::int*, core::int*>* #t352 = <core::int*, core::int*>{};
@@ -2417,17 +2417,17 @@
                                                             ^" in "bar" as{TypeError} core::int*}.{core::Map::entries}.{core::Iterable::iterator};
             for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
               final core::MapEntry<core::int*, core::int*>* #t355 = :sync-for-iterator.{core::Iterator::current};
-              #t352.{core::Map::[]=}(#t355.{core::MapEntry::key}, #t355.{core::MapEntry::value});
+              #t352.{core::Map::[]=}{Invariant}(#t355.{core::MapEntry::key}, #t355.{core::MapEntry::value});
             }
           }
-          #t352.{core::Map::[]=}(let final<BottomType> #t356 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:215:69: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+          #t352.{core::Map::[]=}{Invariant}(let final<BottomType> #t356 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:215:69: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int, int>{for (int i = 0; oracle(\"foo\"); i++) ...{\"bar\": \"bar\"}, \"baz\": null};
                                                                     ^" in "baz" as{TypeError} core::int*, null);
         } =>#t352;
         block {
           final core::List<core::int*>* #t357 = <core::int*>[];
           for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-            #t357.{core::List::add}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:216:48: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+            #t357.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:216:48: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>[for (int i = 0; oracle(\"foo\"); i++) ...map];
                                                ^");
@@ -2435,11 +2435,11 @@
         block {
           final core::Set<core::int*>* #t358 = new col::_CompactLinkedHashSet::•<core::int*>();
           for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-            #t358.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:217:48: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+            #t358.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:217:48: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>{for (int i = 0; oracle(\"foo\"); i++) ...map, null};
                                                ^");
-          #t358.{core::Set::add}(null);
+          #t358.{core::Set::add}{Invariant}(null);
         } =>#t358;
         <core::int*, core::int*>{invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:218:53: Error: Unexpected type 'List<int>' of a map spread entry.  Expected 'dynamic' or a Map.
  - 'List' is from 'dart:core'.
@@ -2452,11 +2452,11 @@
           final core::List<core::String*>* #t359 = <core::String*>[];
           for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
             if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-              #t359.{core::List::add}(let final<BottomType> #t360 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:219:62: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+              #t359.{core::List::add}{Invariant}(let final<BottomType> #t360 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:219:62: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   <String>[for (int i = 0; oracle(\"foo\"); i++) if (oracle()) 42 else 3.14];
                                                              ^" in 42 as{TypeError} core::String*);
             else
-              #t359.{core::List::add}(let final<BottomType> #t361 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:219:70: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
+              #t359.{core::List::add}{Invariant}(let final<BottomType> #t361 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:219:70: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
   <String>[for (int i = 0; oracle(\"foo\"); i++) if (oracle()) 42 else 3.14];
                                                                      ^" in 3.14 as{TypeError} core::String*);
         } =>#t359;
@@ -2464,50 +2464,50 @@
           final core::Set<core::String*>* #t362 = new col::_CompactLinkedHashSet::•<core::String*>();
           for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
             if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-              #t362.{core::Set::add}(let final<BottomType> #t363 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:220:62: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+              #t362.{core::Set::add}{Invariant}(let final<BottomType> #t363 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:220:62: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   <String>{for (int i = 0; oracle(\"foo\"); i++) if (oracle()) 42 else 3.14, null};
                                                              ^" in 42 as{TypeError} core::String*);
             else
-              #t362.{core::Set::add}(let final<BottomType> #t364 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:220:70: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
+              #t362.{core::Set::add}{Invariant}(let final<BottomType> #t364 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:220:70: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
   <String>{for (int i = 0; oracle(\"foo\"); i++) if (oracle()) 42 else 3.14, null};
                                                                      ^" in 3.14 as{TypeError} core::String*);
-          #t362.{core::Set::add}(null);
+          #t362.{core::Set::add}{Invariant}(null);
         } =>#t362;
         block {
           final core::Map<core::String*, core::String*>* #t365 = <core::String*, core::String*>{};
           for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
             if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-              #t365.{core::Map::[]=}("bar", let final<BottomType> #t366 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:221:77: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+              #t365.{core::Map::[]=}{Invariant}("bar", let final<BottomType> #t366 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:221:77: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   <String, String>{for (int i = 0; oracle(\"foo\"); i++) if (oracle()) \"bar\": 42 else \"bar\": 3.14, \"baz\": null};
                                                                             ^" in 42 as{TypeError} core::String*);
             else
-              #t365.{core::Map::[]=}("bar", let final<BottomType> #t367 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:221:92: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
+              #t365.{core::Map::[]=}{Invariant}("bar", let final<BottomType> #t367 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:221:92: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
   <String, String>{for (int i = 0; oracle(\"foo\"); i++) if (oracle()) \"bar\": 42 else \"bar\": 3.14, \"baz\": null};
                                                                                            ^" in 3.14 as{TypeError} core::String*);
-          #t365.{core::Map::[]=}("baz", null);
+          #t365.{core::Map::[]=}{Invariant}("baz", null);
         } =>#t365;
         block {
           final core::List<core::int*>* #t368 = <core::int*>[];
           for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
             if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-              #t368.{core::List::add}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:222:62: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+              #t368.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:222:62: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>[for (int i = 0; oracle(\"foo\"); i++) if (oracle()) ...map else 42];
                                                              ^");
             else
-              #t368.{core::List::add}(42);
+              #t368.{core::List::add}{Invariant}(42);
         } =>#t368;
         block {
           final core::Set<core::int*>* #t369 = new col::_CompactLinkedHashSet::•<core::int*>();
           for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
             if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-              #t369.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:223:62: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+              #t369.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:223:62: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>{for (int i = 0; oracle(\"foo\"); i++) if (oracle()) ...map else 42, null};
                                                              ^");
             else
-              #t369.{core::Set::add}(42);
-          #t369.{core::Set::add}(null);
+              #t369.{core::Set::add}{Invariant}(42);
+          #t369.{core::Set::add}{Invariant}(null);
         } =>#t369;
         <core::String*, core::int*>{invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:224:70: Error: Unexpected type 'List<int>' of a map spread entry.  Expected 'dynamic' or a Map.
  - 'List' is from 'dart:core'.
@@ -2520,9 +2520,9 @@
           final core::List<core::int*>* #t370 = <core::int*>[];
           for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
             if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-              #t370.{core::List::add}(42);
+              #t370.{core::List::add}{Invariant}(42);
             else
-              #t370.{core::List::add}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:225:70: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+              #t370.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:225:70: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>[for (int i = 0; oracle(\"foo\"); i++) if (oracle()) 42 else ...map];
                                                                      ^");
@@ -2531,13 +2531,13 @@
           final core::Set<core::int*>* #t371 = new col::_CompactLinkedHashSet::•<core::int*>();
           for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
             if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-              #t371.{core::Set::add}(42);
+              #t371.{core::Set::add}{Invariant}(42);
             else
-              #t371.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:226:70: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+              #t371.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:226:70: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>{for (int i = 0; oracle(\"foo\"); i++) if (oracle()) 42 else ...map, null};
                                                                      ^");
-          #t371.{core::Set::add}(null);
+          #t371.{core::Set::add}{Invariant}(null);
         } =>#t371;
         <core::String*, core::int*>{invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:227:85: Error: Unexpected type 'List<int>' of a map spread entry.  Expected 'dynamic' or a Map.
  - 'List' is from 'dart:core'.
@@ -2557,7 +2557,7 @@
                 invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:230:14: Error: Can't assign to the final variable 'i'.
   <int>[for (i in <int>[1]) i];
              ^";
-                #t372.{core::List::add}(i);
+                #t372.{core::List::add}{Invariant}(i);
               }
             }
           }
@@ -2572,11 +2572,11 @@
                 invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:231:14: Error: Can't assign to the final variable 'i'.
   <int>{for (i in <int>[1]) i, null};
              ^";
-                #t374.{core::Set::add}(i);
+                #t374.{core::Set::add}{Invariant}(i);
               }
             }
           }
-          #t374.{core::Set::add}(null);
+          #t374.{core::Set::add}{Invariant}(null);
         } =>#t374;
         block {
           final core::Map<core::String*, core::int*>* #t376 = <core::String*, core::int*>{};
@@ -2588,11 +2588,11 @@
                 invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:232:21: Error: Can't assign to the final variable 'i'.
 \t<String, int>{for (i in <int>[1]) \"bar\": i, \"baz\": null};
 \t                   ^";
-                #t376.{core::Map::[]=}("bar", i);
+                #t376.{core::Map::[]=}{Invariant}("bar", i);
               }
             }
           }
-          #t376.{core::Map::[]=}("baz", null);
+          #t376.{core::Map::[]=}{Invariant}("baz", null);
         } =>#t376;
         core::List<dynamic>* list10 = block {
           final core::List<dynamic>* #t378 = <dynamic>[];
@@ -2603,7 +2603,7 @@
                               ^" in "not iterable" as{TypeError} core::Iterable<dynamic>*).{core::Iterable::iterator};
             for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
               dynamic i = :sync-for-iterator.{core::Iterator::current};
-              #t378.{core::List::add}(i);
+              #t378.{core::List::add}{Invariant}(i);
             }
           }
         } =>#t378;
@@ -2616,10 +2616,10 @@
                              ^" in "not iterable" as{TypeError} core::Iterable<dynamic>*).{core::Iterable::iterator};
             for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
               dynamic i = :sync-for-iterator.{core::Iterator::current};
-              #t380.{core::Set::add}(i);
+              #t380.{core::Set::add}{Invariant}(i);
             }
           }
-          #t380.{core::Set::add}(null);
+          #t380.{core::Set::add}{Invariant}(null);
         } =>#t380;
         core::Map<core::String*, dynamic>* map10 = block {
           final core::Map<core::String*, dynamic>* #t382 = <core::String*, dynamic>{};
@@ -2630,10 +2630,10 @@
                              ^" in "not iterable" as{TypeError} core::Iterable<dynamic>*).{core::Iterable::iterator};
             for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
               dynamic i = :sync-for-iterator.{core::Iterator::current};
-              #t382.{core::Map::[]=}("bar", i);
+              #t382.{core::Map::[]=}{Invariant}("bar", i);
             }
           }
-          #t382.{core::Map::[]=}("baz", null);
+          #t382.{core::Map::[]=}{Invariant}("baz", null);
         } =>#t382;
         core::List<core::int*>* list20 = block {
           final core::List<core::int*>* #t384 = <core::int*>[];
@@ -2645,7 +2645,7 @@
                                       ^" in "int" as{TypeError} core::int*].{core::Iterable::iterator};
             for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
               core::int* i = :sync-for-iterator.{core::Iterator::current};
-              #t384.{core::List::add}(i);
+              #t384.{core::List::add}{Invariant}(i);
             }
           }
         } =>#t384;
@@ -2659,10 +2659,10 @@
                                      ^" in "int" as{TypeError} core::int*].{core::Iterable::iterator};
             for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
               core::int* i = :sync-for-iterator.{core::Iterator::current};
-              #t387.{core::Set::add}(i);
+              #t387.{core::Set::add}{Invariant}(i);
             }
           }
-          #t387.{core::Set::add}(null);
+          #t387.{core::Set::add}{Invariant}(null);
         } =>#t387;
         core::Map<core::String*, core::int*>* map20 = block {
           final core::Map<core::String*, core::int*>* #t390 = <core::String*, core::int*>{};
@@ -2674,10 +2674,10 @@
                                      ^" in "int" as{TypeError} core::int*].{core::Iterable::iterator};
             for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
               core::int* i = :sync-for-iterator.{core::Iterator::current};
-              #t390.{core::Map::[]=}("bar", i);
+              #t390.{core::Map::[]=}{Invariant}("bar", i);
             }
           }
-          #t390.{core::Map::[]=}("baz", null);
+          #t390.{core::Map::[]=}{Invariant}("baz", null);
         } =>#t390;
         final core::List<dynamic>* #t393 = <dynamic>[];
         {
@@ -2693,7 +2693,7 @@
               [yield] let dynamic #t396 = asy::_awaitHelper(:for-iterator.{asy::_StreamIterator::moveNext}(), :async_op_then, :async_op_error, :async_op) in null;
               if(_in::unsafeCast<core::bool>(:result)) {
                 dynamic i = :for-iterator.{asy::_StreamIterator::current};
-                #t393.{core::List::add}(i);
+                #t393.{core::List::add}{Invariant}(i);
               }
               else
                 break #L2;
@@ -2719,7 +2719,7 @@
               [yield] let dynamic #t401 = asy::_awaitHelper(:for-iterator.{asy::_StreamIterator::moveNext}(), :async_op_then, :async_op_error, :async_op) in null;
               if(_in::unsafeCast<core::bool>(:result)) {
                 dynamic i = :for-iterator.{asy::_StreamIterator::current};
-                #t398.{core::Set::add}(i);
+                #t398.{core::Set::add}{Invariant}(i);
               }
               else
                 break #L3;
@@ -2731,7 +2731,7 @@
             }
         }
         core::Set<dynamic>* set30 = block {
-          #t398.{core::Set::add}(null);
+          #t398.{core::Set::add}{Invariant}(null);
         } =>#t398;
         final core::Map<core::String*, dynamic>* #t403 = <core::String*, dynamic>{};
         {
@@ -2747,7 +2747,7 @@
               [yield] let dynamic #t406 = asy::_awaitHelper(:for-iterator.{asy::_StreamIterator::moveNext}(), :async_op_then, :async_op_error, :async_op) in null;
               if(_in::unsafeCast<core::bool>(:result)) {
                 dynamic i = :for-iterator.{asy::_StreamIterator::current};
-                #t403.{core::Map::[]=}("bar", i);
+                #t403.{core::Map::[]=}{Invariant}("bar", i);
               }
               else
                 break #L4;
@@ -2759,7 +2759,7 @@
             }
         }
         core::Map<core::String*, dynamic>* map30 = block {
-          #t403.{core::Map::[]=}("baz", null);
+          #t403.{core::Map::[]=}{Invariant}("baz", null);
         } =>#t403;
         final core::List<core::int*>* #t408 = <core::int*>[];
         {
@@ -2776,7 +2776,7 @@
               [yield] let dynamic #t412 = asy::_awaitHelper(:for-iterator.{asy::_StreamIterator::moveNext}(), :async_op_then, :async_op_error, :async_op) in null;
               if(_in::unsafeCast<core::bool>(:result)) {
                 core::int* i = :for-iterator.{asy::_StreamIterator::current};
-                #t408.{core::List::add}(i);
+                #t408.{core::List::add}{Invariant}(i);
               }
               else
                 break #L5;
@@ -2803,7 +2803,7 @@
               [yield] let dynamic #t418 = asy::_awaitHelper(:for-iterator.{asy::_StreamIterator::moveNext}(), :async_op_then, :async_op_error, :async_op) in null;
               if(_in::unsafeCast<core::bool>(:result)) {
                 core::int* i = :for-iterator.{asy::_StreamIterator::current};
-                #t414.{core::Set::add}(i);
+                #t414.{core::Set::add}{Invariant}(i);
               }
               else
                 break #L6;
@@ -2815,7 +2815,7 @@
             }
         }
         core::Set<core::int*>* set40 = block {
-          #t414.{core::Set::add}(null);
+          #t414.{core::Set::add}{Invariant}(null);
         } =>#t414;
         final core::Map<core::String*, core::int*>* #t420 = <core::String*, core::int*>{};
         {
@@ -2832,7 +2832,7 @@
               [yield] let dynamic #t424 = asy::_awaitHelper(:for-iterator.{asy::_StreamIterator::moveNext}(), :async_op_then, :async_op_error, :async_op) in null;
               if(_in::unsafeCast<core::bool>(:result)) {
                 core::int* i = :for-iterator.{asy::_StreamIterator::current};
-                #t420.{core::Map::[]=}("bar", i);
+                #t420.{core::Map::[]=}{Invariant}("bar", i);
               }
               else
                 break #L7;
@@ -2844,47 +2844,47 @@
             }
         }
         core::Map<core::String*, core::int*>* map40 = block {
-          #t420.{core::Map::[]=}("baz", null);
+          #t420.{core::Map::[]=}{Invariant}("baz", null);
         } =>#t420;
         core::List<core::int*>* list50 = block {
           final core::List<core::int*>* #t426 = <core::int*>[];
           for (; ; )
-            #t426.{core::List::add}(42);
+            #t426.{core::List::add}{Invariant}(42);
         } =>#t426;
         core::Set<core::int*>* set50 = block {
           final core::Set<core::int*>* #t427 = new col::_CompactLinkedHashSet::•<core::int*>();
           for (; ; )
-            #t427.{core::Set::add}(42);
-          #t427.{core::Set::add}(null);
+            #t427.{core::Set::add}{Invariant}(42);
+          #t427.{core::Set::add}{Invariant}(null);
         } =>#t427;
         core::Map<core::String*, core::int*>* map50 = block {
           final core::Map<core::String*, core::int*>* #t428 = <core::String*, core::int*>{};
           for (; ; )
-            #t428.{core::Map::[]=}("bar", 42);
-          #t428.{core::Map::[]=}("baz", null);
+            #t428.{core::Map::[]=}{Invariant}("bar", 42);
+          #t428.{core::Map::[]=}{Invariant}("baz", null);
         } =>#t428;
         core::List<core::int*>* list60 = block {
           final core::List<core::int*>* #t429 = <core::int*>[];
           for (; let final<BottomType> #t430 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:249:24: Error: A value of type 'String' can't be assigned to a variable of type 'bool'.
   var list60 = [for (; \"not bool\";) 42];
                        ^" in "not bool" as{TypeError} core::bool*; )
-            #t429.{core::List::add}(42);
+            #t429.{core::List::add}{Invariant}(42);
         } =>#t429;
         core::Set<core::int*>* set60 = block {
           final core::Set<core::int*>* #t431 = new col::_CompactLinkedHashSet::•<core::int*>();
           for (; let final<BottomType> #t432 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:250:23: Error: A value of type 'String' can't be assigned to a variable of type 'bool'.
   var set60 = {for (; \"not bool\";) 42, null};
                       ^" in "not bool" as{TypeError} core::bool*; )
-            #t431.{core::Set::add}(42);
-          #t431.{core::Set::add}(null);
+            #t431.{core::Set::add}{Invariant}(42);
+          #t431.{core::Set::add}{Invariant}(null);
         } =>#t431;
         core::Map<core::String*, core::int*>* map60 = block {
           final core::Map<core::String*, core::int*>* #t433 = <core::String*, core::int*>{};
           for (; let final<BottomType> #t434 = invalid-expression "pkg/front_end/testcases/general/control_flow_collection_inference.dart:251:23: Error: A value of type 'String' can't be assigned to a variable of type 'bool'.
   var map60 = {for (; \"not bool\";) \"bar\": 42, \"baz\": null};
                       ^" in "not bool" as{TypeError} core::bool*; )
-            #t433.{core::Map::[]=}("bar", 42);
-          #t433.{core::Map::[]=}("baz", null);
+            #t433.{core::Map::[]=}{Invariant}("bar", 42);
+          #t433.{core::Map::[]=}{Invariant}("baz", null);
         } =>#t433;
       }
       asy::_completeOnAsyncReturn(:async_future, :return_value, :is_sync);
@@ -2904,34 +2904,34 @@
   block {
     final core::List<core::int*>* #t435 = <core::int*>[];
     await for (core::int* i in stream)
-      #t435.{core::List::add}(i);
+      #t435.{core::List::add}{Invariant}(i);
   } =>#t435;
   block {
     final core::Set<core::int*>* #t436 = new col::_CompactLinkedHashSet::•<core::int*>();
     await for (core::int* i in stream)
-      #t436.{core::Set::add}(i);
+      #t436.{core::Set::add}{Invariant}(i);
   } =>#t436;
   block {
     final core::Map<core::String*, core::int*>* #t437 = <core::String*, core::int*>{};
     await for (core::int* i in stream)
-      #t437.{core::Map::[]=}("bar", i);
+      #t437.{core::Map::[]=}{Invariant}("bar", i);
   } =>#t437;
 }
 static method testPromotion(self::A* a) → dynamic {
   core::List<core::int*>* list10 = block {
     final core::List<core::int*>* #t438 = <core::int*>[];
     if(a is self::B*)
-      #t438.{core::List::add}(a{self::B*}.{self::B::foo});
+      #t438.{core::List::add}{Invariant}(a{self::B*}.{self::B::foo});
   } =>#t438;
   core::Set<core::int*>* set10 = block {
     final core::Set<core::int*>* #t439 = new col::_CompactLinkedHashSet::•<core::int*>();
     if(a is self::B*)
-      #t439.{core::Set::add}(a{self::B*}.{self::B::foo});
+      #t439.{core::Set::add}{Invariant}(a{self::B*}.{self::B::foo});
   } =>#t439;
   core::Map<core::int*, core::int*>* map10 = block {
     final core::Map<core::int*, core::int*>* #t440 = <core::int*, core::int*>{};
     if(a is self::B*)
-      #t440.{core::Map::[]=}(a{self::B*}.{self::B::foo}, a{self::B*}.{self::B::foo});
+      #t440.{core::Map::[]=}{Invariant}(a{self::B*}.{self::B::foo}, a{self::B*}.{self::B::foo});
   } =>#t440;
 }
 static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/general/if_null_in_set_literal.dart.strong.expect b/pkg/front_end/testcases/general/if_null_in_set_literal.dart.strong.expect
index cf3316a..bbc6109 100644
--- a/pkg/front_end/testcases/general/if_null_in_set_literal.dart.strong.expect
+++ b/pkg/front_end/testcases/general/if_null_in_set_literal.dart.strong.expect
@@ -8,6 +8,6 @@
   core::Object* b;
   return block {
     final core::Set<core::Object*>* #t1 = col::LinkedHashSet::•<core::Object*>();
-    #t1.{core::Set::add}(let final core::Object* #t2 = a in #t2.{core::Object::==}(null) ?{core::Object*} b : #t2);
+    #t1.{core::Set::add}{Invariant}(let final core::Object* #t2 = a in #t2.{core::Object::==}(null) ?{core::Object*} b : #t2);
   } =>#t1;
 }
diff --git a/pkg/front_end/testcases/general/if_null_in_set_literal.dart.strong.transformed.expect b/pkg/front_end/testcases/general/if_null_in_set_literal.dart.strong.transformed.expect
index d304f46..637e41b 100644
--- a/pkg/front_end/testcases/general/if_null_in_set_literal.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/general/if_null_in_set_literal.dart.strong.transformed.expect
@@ -8,6 +8,6 @@
   core::Object* b;
   return block {
     final core::Set<core::Object*>* #t1 = new col::_CompactLinkedHashSet::•<core::Object*>();
-    #t1.{core::Set::add}(let final core::Object* #t2 = a in #t2.{core::Object::==}(null) ?{core::Object*} b : #t2);
+    #t1.{core::Set::add}{Invariant}(let final core::Object* #t2 = a in #t2.{core::Object::==}(null) ?{core::Object*} b : #t2);
   } =>#t1;
 }
diff --git a/pkg/front_end/testcases/general/issue31767.dart b/pkg/front_end/testcases/general/issue31767.dart
new file mode 100644
index 0000000..045dced
--- /dev/null
+++ b/pkg/front_end/testcases/general/issue31767.dart
@@ -0,0 +1,61 @@
+// Copyright (c) 2020, the Dart project authors.  Please see the AUTHORS file
+// for details. All rights reserved. Use of this source code is governed by a
+// BSD-style license that can be found in the LICENSE file.
+
+// @dart=2.9
+
+import 'issue31767_lib.dart';
+
+StringBuffer sb;
+
+class C {
+  final int w;
+  C.foo(int x, [int y = 0, int z = 0]) : w = p("x", x) + p("y", y) + p("z", z);
+}
+
+int p(String name, int value) {
+  sb.write("$name = $value, ");
+  return value;
+}
+
+mixin M on C {
+  int get w2 => w * w;
+}
+
+class D = C with M;
+
+mixin N on A {
+  int get w2 => w * w;
+}
+
+class E = A with N;
+
+main() {
+  sb = new StringBuffer();
+  var a = A.foo(1, 2);
+  expect('x = 1, y = 2, z = 3, ', sb.toString());
+  expect(6, a.w);
+  expect(5, a.a.field);
+
+  sb = new StringBuffer();
+  var c = C.foo(1, 2);
+  expect('x = 1, y = 2, z = 0, ', sb.toString());
+  expect(3, c.w);
+
+  sb = new StringBuffer();
+  var d = D.foo(1, 2);
+  expect('x = 1, y = 2, z = 0, ', sb.toString());
+  expect(3, d.w);
+  expect(9, d.w2);
+
+  sb = new StringBuffer();
+  var e = E.foo(1, 2);
+  expect('x = 1, y = 2, z = 3, ', sb.toString());
+  expect(6, e.w);
+  expect(36, e.w2);
+  expect(5, e.a.field);
+}
+
+expect(expected, actual) {
+  if (expected != actual) throw 'Expected $expected, actual $actual';
+}
diff --git a/pkg/front_end/testcases/general/issue31767.dart.outline.expect b/pkg/front_end/testcases/general/issue31767.dart.outline.expect
new file mode 100644
index 0000000..adbdb2c
--- /dev/null
+++ b/pkg/front_end/testcases/general/issue31767.dart.outline.expect
@@ -0,0 +1,87 @@
+library;
+import self as self;
+import "dart:core" as core;
+import "issue31767_lib.dart" as iss;
+
+import "org-dartlang-testcase:///issue31767_lib.dart";
+
+class C extends core::Object {
+  final field core::int* w;
+  constructor foo(core::int* x, [core::int* y, core::int* z]) → self::C*
+    ;
+  abstract member-signature get _identityHashCode() → core::int*; -> core::Object::_identityHashCode
+  abstract member-signature method _instanceOf(dynamic instantiatorTypeArguments, dynamic functionTypeArguments, dynamic type) → core::bool*; -> core::Object::_instanceOf
+  abstract member-signature method _simpleInstanceOf(dynamic type) → core::bool*; -> core::Object::_simpleInstanceOf
+  abstract member-signature method _simpleInstanceOfTrue(dynamic type) → core::bool*; -> core::Object::_simpleInstanceOfTrue
+  abstract member-signature method _simpleInstanceOfFalse(dynamic type) → core::bool*; -> core::Object::_simpleInstanceOfFalse
+  abstract member-signature operator ==(dynamic other) → core::bool*; -> core::Object::==
+  abstract member-signature get hashCode() → core::int*; -> core::Object::hashCode
+  abstract member-signature method toString() → core::String*; -> core::Object::toString
+  abstract member-signature method noSuchMethod(core::Invocation* invocation) → dynamic; -> core::Object::noSuchMethod
+  abstract member-signature get runtimeType() → core::Type*; -> core::Object::runtimeType
+}
+abstract class M extends self::C /*isMixinDeclaration*/  {
+  get w2() → core::int*
+    ;
+}
+class D = self::C with self::M {
+  synthetic constructor foo(core::int* x, [core::int* y, core::int* z]) → self::D*
+    : super self::C::foo(x, y, z)
+    ;
+}
+abstract class N extends iss::A /*isMixinDeclaration*/  {
+  get w2() → core::int*
+    ;
+}
+class E = iss::A with self::N {
+  synthetic constructor foo(core::int* x, [core::int* y, core::int* z, iss::_A* a]) → self::E*
+    : super iss::A::foo(x, y, z, a)
+    ;
+}
+static field core::StringBuffer* sb;
+static method p(core::String* name, core::int* value) → core::int*
+  ;
+static method main() → dynamic
+  ;
+static method expect(dynamic expected, dynamic actual) → dynamic
+  ;
+
+library;
+import self as iss;
+import "dart:core" as core;
+
+import "org-dartlang-testcase:///issue31767.dart";
+
+class A extends core::Object {
+  final field core::int* w;
+  final field iss::_A* a;
+  constructor foo(core::int* x, [core::int* y, core::int* z, iss::_A* a]) → iss::A*
+    ;
+  abstract member-signature get _identityHashCode() → core::int*; -> core::Object::_identityHashCode
+  abstract member-signature method _instanceOf(dynamic instantiatorTypeArguments, dynamic functionTypeArguments, dynamic type) → core::bool*; -> core::Object::_instanceOf
+  abstract member-signature method _simpleInstanceOf(dynamic type) → core::bool*; -> core::Object::_simpleInstanceOf
+  abstract member-signature method _simpleInstanceOfTrue(dynamic type) → core::bool*; -> core::Object::_simpleInstanceOfTrue
+  abstract member-signature method _simpleInstanceOfFalse(dynamic type) → core::bool*; -> core::Object::_simpleInstanceOfFalse
+  abstract member-signature operator ==(dynamic other) → core::bool*; -> core::Object::==
+  abstract member-signature get hashCode() → core::int*; -> core::Object::hashCode
+  abstract member-signature method toString() → core::String*; -> core::Object::toString
+  abstract member-signature method noSuchMethod(core::Invocation* invocation) → dynamic; -> core::Object::noSuchMethod
+  abstract member-signature get runtimeType() → core::Type*; -> core::Object::runtimeType
+}
+class _A extends core::Object /*hasConstConstructor*/  {
+  final field core::int* field;
+  const constructor •(core::int* field) → iss::_A*
+    : iss::_A::field = field, super core::Object::•()
+    ;
+  abstract member-signature get _identityHashCode() → core::int*; -> core::Object::_identityHashCode
+  abstract member-signature method _instanceOf(dynamic instantiatorTypeArguments, dynamic functionTypeArguments, dynamic type) → core::bool*; -> core::Object::_instanceOf
+  abstract member-signature method _simpleInstanceOf(dynamic type) → core::bool*; -> core::Object::_simpleInstanceOf
+  abstract member-signature method _simpleInstanceOfTrue(dynamic type) → core::bool*; -> core::Object::_simpleInstanceOfTrue
+  abstract member-signature method _simpleInstanceOfFalse(dynamic type) → core::bool*; -> core::Object::_simpleInstanceOfFalse
+  abstract member-signature operator ==(dynamic other) → core::bool*; -> core::Object::==
+  abstract member-signature get hashCode() → core::int*; -> core::Object::hashCode
+  abstract member-signature method toString() → core::String*; -> core::Object::toString
+  abstract member-signature method noSuchMethod(core::Invocation* invocation) → dynamic; -> core::Object::noSuchMethod
+  abstract member-signature get runtimeType() → core::Type*; -> core::Object::runtimeType
+}
+static const field core::int* _private = 3;
diff --git a/pkg/front_end/testcases/general/issue31767.dart.strong.expect b/pkg/front_end/testcases/general/issue31767.dart.strong.expect
new file mode 100644
index 0000000..66290c1
--- /dev/null
+++ b/pkg/front_end/testcases/general/issue31767.dart.strong.expect
@@ -0,0 +1,121 @@
+library;
+import self as self;
+import "dart:core" as core;
+import "issue31767_lib.dart" as iss;
+
+import "org-dartlang-testcase:///issue31767_lib.dart";
+
+class C extends core::Object {
+  final field core::int* w;
+  constructor foo(core::int* x, [core::int* y = #C1, core::int* z = #C1]) → self::C*
+    : self::C::w = self::p("x", x).{core::num::+}(self::p("y", y)).{core::num::+}(self::p("z", z)), super core::Object::•()
+    ;
+  abstract member-signature get _identityHashCode() → core::int*; -> core::Object::_identityHashCode
+  abstract member-signature method _instanceOf(dynamic instantiatorTypeArguments, dynamic functionTypeArguments, dynamic type) → core::bool*; -> core::Object::_instanceOf
+  abstract member-signature method _simpleInstanceOf(dynamic type) → core::bool*; -> core::Object::_simpleInstanceOf
+  abstract member-signature method _simpleInstanceOfTrue(dynamic type) → core::bool*; -> core::Object::_simpleInstanceOfTrue
+  abstract member-signature method _simpleInstanceOfFalse(dynamic type) → core::bool*; -> core::Object::_simpleInstanceOfFalse
+  abstract member-signature operator ==(dynamic other) → core::bool*; -> core::Object::==
+  abstract member-signature get hashCode() → core::int*; -> core::Object::hashCode
+  abstract member-signature method toString() → core::String*; -> core::Object::toString
+  abstract member-signature method noSuchMethod(core::Invocation* invocation) → dynamic; -> core::Object::noSuchMethod
+  abstract member-signature get runtimeType() → core::Type*; -> core::Object::runtimeType
+}
+abstract class M extends self::C /*isMixinDeclaration*/  {
+  get w2() → core::int*
+    return this.{self::C::w}.{core::num::*}(this.{self::C::w});
+}
+class D = self::C with self::M {
+  synthetic constructor foo(core::int* x, [core::int* y = #C1, core::int* z = #C1]) → self::D*
+    : super self::C::foo(x, y, z)
+    ;
+}
+abstract class N extends iss::A /*isMixinDeclaration*/  {
+  get w2() → core::int*
+    return this.{iss::A::w}.{core::num::*}(this.{iss::A::w});
+}
+class E = iss::A with self::N {
+  synthetic constructor foo(core::int* x, [core::int* y = #C2, core::int* z = #C2, iss::_A* a = #C4]) → self::E*
+    : super iss::A::foo(x, y, z, a)
+    ;
+}
+static field core::StringBuffer* sb;
+static method p(core::String* name, core::int* value) → core::int* {
+  self::sb.{core::StringBuffer::write}("${name} = ${value}, ");
+  return value;
+}
+static method main() → dynamic {
+  self::sb = new core::StringBuffer::•();
+  iss::A* a = new iss::A::foo(1, 2);
+  self::expect("x = 1, y = 2, z = 3, ", self::sb.{core::StringBuffer::toString}());
+  self::expect(6, a.{iss::A::w});
+  self::expect(5, a.{iss::A::a}.{iss::_A::field});
+  self::sb = new core::StringBuffer::•();
+  self::C* c = new self::C::foo(1, 2);
+  self::expect("x = 1, y = 2, z = 0, ", self::sb.{core::StringBuffer::toString}());
+  self::expect(3, c.{self::C::w});
+  self::sb = new core::StringBuffer::•();
+  self::D* d = new self::D::foo(1, 2);
+  self::expect("x = 1, y = 2, z = 0, ", self::sb.{core::StringBuffer::toString}());
+  self::expect(3, d.{self::C::w});
+  self::expect(9, d.{self::M::w2});
+  self::sb = new core::StringBuffer::•();
+  self::E* e = new self::E::foo(1, 2);
+  self::expect("x = 1, y = 2, z = 3, ", self::sb.{core::StringBuffer::toString}());
+  self::expect(6, e.{iss::A::w});
+  self::expect(36, e.{self::N::w2});
+  self::expect(5, e.{iss::A::a}.{iss::_A::field});
+}
+static method expect(dynamic expected, dynamic actual) → dynamic {
+  if(!expected.{core::Object::==}(actual))
+    throw "Expected ${expected}, actual ${actual}";
+}
+
+library;
+import self as iss;
+import "dart:core" as core;
+import "issue31767.dart" as self;
+
+import "org-dartlang-testcase:///issue31767.dart";
+
+class A extends core::Object {
+  final field core::int* w;
+  final field iss::_A* a;
+  constructor foo(core::int* x, [core::int* y = #C2, core::int* z = #C2, iss::_A* a = #C4]) → iss::A*
+    : iss::A::a = a, iss::A::w = self::p("x", x).{core::num::+}(self::p("y", y)).{core::num::+}(self::p("z", z)), super core::Object::•()
+    ;
+  abstract member-signature get _identityHashCode() → core::int*; -> core::Object::_identityHashCode
+  abstract member-signature method _instanceOf(dynamic instantiatorTypeArguments, dynamic functionTypeArguments, dynamic type) → core::bool*; -> core::Object::_instanceOf
+  abstract member-signature method _simpleInstanceOf(dynamic type) → core::bool*; -> core::Object::_simpleInstanceOf
+  abstract member-signature method _simpleInstanceOfTrue(dynamic type) → core::bool*; -> core::Object::_simpleInstanceOfTrue
+  abstract member-signature method _simpleInstanceOfFalse(dynamic type) → core::bool*; -> core::Object::_simpleInstanceOfFalse
+  abstract member-signature operator ==(dynamic other) → core::bool*; -> core::Object::==
+  abstract member-signature get hashCode() → core::int*; -> core::Object::hashCode
+  abstract member-signature method toString() → core::String*; -> core::Object::toString
+  abstract member-signature method noSuchMethod(core::Invocation* invocation) → dynamic; -> core::Object::noSuchMethod
+  abstract member-signature get runtimeType() → core::Type*; -> core::Object::runtimeType
+}
+class _A extends core::Object /*hasConstConstructor*/  {
+  final field core::int* field;
+  const constructor •(core::int* field) → iss::_A*
+    : iss::_A::field = field, super core::Object::•()
+    ;
+  abstract member-signature get _identityHashCode() → core::int*; -> core::Object::_identityHashCode
+  abstract member-signature method _instanceOf(dynamic instantiatorTypeArguments, dynamic functionTypeArguments, dynamic type) → core::bool*; -> core::Object::_instanceOf
+  abstract member-signature method _simpleInstanceOf(dynamic type) → core::bool*; -> core::Object::_simpleInstanceOf
+  abstract member-signature method _simpleInstanceOfTrue(dynamic type) → core::bool*; -> core::Object::_simpleInstanceOfTrue
+  abstract member-signature method _simpleInstanceOfFalse(dynamic type) → core::bool*; -> core::Object::_simpleInstanceOfFalse
+  abstract member-signature operator ==(dynamic other) → core::bool*; -> core::Object::==
+  abstract member-signature get hashCode() → core::int*; -> core::Object::hashCode
+  abstract member-signature method toString() → core::String*; -> core::Object::toString
+  abstract member-signature method noSuchMethod(core::Invocation* invocation) → dynamic; -> core::Object::noSuchMethod
+  abstract member-signature get runtimeType() → core::Type*; -> core::Object::runtimeType
+}
+static const field core::int* _private = #C2;
+
+constants  {
+  #C1 = 0
+  #C2 = 3
+  #C3 = 5
+  #C4 = iss::_A {field:#C3}
+}
diff --git a/pkg/front_end/testcases/general/issue31767.dart.strong.transformed.expect b/pkg/front_end/testcases/general/issue31767.dart.strong.transformed.expect
new file mode 100644
index 0000000..19fdcee
--- /dev/null
+++ b/pkg/front_end/testcases/general/issue31767.dart.strong.transformed.expect
@@ -0,0 +1,125 @@
+library;
+import self as self;
+import "dart:core" as core;
+import "issue31767_lib.dart" as iss;
+
+import "org-dartlang-testcase:///issue31767_lib.dart";
+
+class C extends core::Object {
+  final field core::int* w;
+  constructor foo(core::int* x, [core::int* y = #C1, core::int* z = #C1]) → self::C*
+    : self::C::w = self::p("x", x).{core::num::+}(self::p("y", y)).{core::num::+}(self::p("z", z)), super core::Object::•()
+    ;
+  abstract member-signature get _identityHashCode() → core::int*; -> core::Object::_identityHashCode
+  abstract member-signature method _instanceOf(dynamic instantiatorTypeArguments, dynamic functionTypeArguments, dynamic type) → core::bool*; -> core::Object::_instanceOf
+  abstract member-signature method _simpleInstanceOf(dynamic type) → core::bool*; -> core::Object::_simpleInstanceOf
+  abstract member-signature method _simpleInstanceOfTrue(dynamic type) → core::bool*; -> core::Object::_simpleInstanceOfTrue
+  abstract member-signature method _simpleInstanceOfFalse(dynamic type) → core::bool*; -> core::Object::_simpleInstanceOfFalse
+  abstract member-signature operator ==(dynamic other) → core::bool*; -> core::Object::==
+  abstract member-signature get hashCode() → core::int*; -> core::Object::hashCode
+  abstract member-signature method toString() → core::String*; -> core::Object::toString
+  abstract member-signature method noSuchMethod(core::Invocation* invocation) → dynamic; -> core::Object::noSuchMethod
+  abstract member-signature get runtimeType() → core::Type*; -> core::Object::runtimeType
+}
+abstract class M extends self::C /*isMixinDeclaration*/  {
+  get w2() → core::int*
+    return this.{self::C::w}.{core::num::*}(this.{self::C::w});
+}
+class D extends self::C implements self::M /*isEliminatedMixin*/  {
+  synthetic constructor foo(core::int* x, [core::int* y = #C1, core::int* z = #C1]) → self::D*
+    : super self::C::foo(x, y, z)
+    ;
+  get w2() → core::int*
+    return this.{self::C::w}.{core::num::*}(this.{self::C::w});
+}
+abstract class N extends iss::A /*isMixinDeclaration*/  {
+  get w2() → core::int*
+    return this.{iss::A::w}.{core::num::*}(this.{iss::A::w});
+}
+class E extends iss::A implements self::N /*isEliminatedMixin*/  {
+  synthetic constructor foo(core::int* x, [core::int* y = #C2, core::int* z = #C2, iss::_A* a = #C4]) → self::E*
+    : super iss::A::foo(x, y, z, a)
+    ;
+  get w2() → core::int*
+    return this.{iss::A::w}.{core::num::*}(this.{iss::A::w});
+}
+static field core::StringBuffer* sb;
+static method p(core::String* name, core::int* value) → core::int* {
+  self::sb.{core::StringBuffer::write}("${name} = ${value}, ");
+  return value;
+}
+static method main() → dynamic {
+  self::sb = new core::StringBuffer::•();
+  iss::A* a = new iss::A::foo(1, 2);
+  self::expect("x = 1, y = 2, z = 3, ", self::sb.{core::StringBuffer::toString}());
+  self::expect(6, a.{iss::A::w});
+  self::expect(5, a.{iss::A::a}.{iss::_A::field});
+  self::sb = new core::StringBuffer::•();
+  self::C* c = new self::C::foo(1, 2);
+  self::expect("x = 1, y = 2, z = 0, ", self::sb.{core::StringBuffer::toString}());
+  self::expect(3, c.{self::C::w});
+  self::sb = new core::StringBuffer::•();
+  self::D* d = new self::D::foo(1, 2);
+  self::expect("x = 1, y = 2, z = 0, ", self::sb.{core::StringBuffer::toString}());
+  self::expect(3, d.{self::C::w});
+  self::expect(9, d.{self::M::w2});
+  self::sb = new core::StringBuffer::•();
+  self::E* e = new self::E::foo(1, 2);
+  self::expect("x = 1, y = 2, z = 3, ", self::sb.{core::StringBuffer::toString}());
+  self::expect(6, e.{iss::A::w});
+  self::expect(36, e.{self::N::w2});
+  self::expect(5, e.{iss::A::a}.{iss::_A::field});
+}
+static method expect(dynamic expected, dynamic actual) → dynamic {
+  if(!expected.{core::Object::==}(actual))
+    throw "Expected ${expected}, actual ${actual}";
+}
+
+library;
+import self as iss;
+import "dart:core" as core;
+import "issue31767.dart" as self;
+
+import "org-dartlang-testcase:///issue31767.dart";
+
+class A extends core::Object {
+  final field core::int* w;
+  final field iss::_A* a;
+  constructor foo(core::int* x, [core::int* y = #C2, core::int* z = #C2, iss::_A* a = #C4]) → iss::A*
+    : iss::A::a = a, iss::A::w = self::p("x", x).{core::num::+}(self::p("y", y)).{core::num::+}(self::p("z", z)), super core::Object::•()
+    ;
+  abstract member-signature get _identityHashCode() → core::int*; -> core::Object::_identityHashCode
+  abstract member-signature method _instanceOf(dynamic instantiatorTypeArguments, dynamic functionTypeArguments, dynamic type) → core::bool*; -> core::Object::_instanceOf
+  abstract member-signature method _simpleInstanceOf(dynamic type) → core::bool*; -> core::Object::_simpleInstanceOf
+  abstract member-signature method _simpleInstanceOfTrue(dynamic type) → core::bool*; -> core::Object::_simpleInstanceOfTrue
+  abstract member-signature method _simpleInstanceOfFalse(dynamic type) → core::bool*; -> core::Object::_simpleInstanceOfFalse
+  abstract member-signature operator ==(dynamic other) → core::bool*; -> core::Object::==
+  abstract member-signature get hashCode() → core::int*; -> core::Object::hashCode
+  abstract member-signature method toString() → core::String*; -> core::Object::toString
+  abstract member-signature method noSuchMethod(core::Invocation* invocation) → dynamic; -> core::Object::noSuchMethod
+  abstract member-signature get runtimeType() → core::Type*; -> core::Object::runtimeType
+}
+class _A extends core::Object /*hasConstConstructor*/  {
+  final field core::int* field;
+  const constructor •(core::int* field) → iss::_A*
+    : iss::_A::field = field, super core::Object::•()
+    ;
+  abstract member-signature get _identityHashCode() → core::int*; -> core::Object::_identityHashCode
+  abstract member-signature method _instanceOf(dynamic instantiatorTypeArguments, dynamic functionTypeArguments, dynamic type) → core::bool*; -> core::Object::_instanceOf
+  abstract member-signature method _simpleInstanceOf(dynamic type) → core::bool*; -> core::Object::_simpleInstanceOf
+  abstract member-signature method _simpleInstanceOfTrue(dynamic type) → core::bool*; -> core::Object::_simpleInstanceOfTrue
+  abstract member-signature method _simpleInstanceOfFalse(dynamic type) → core::bool*; -> core::Object::_simpleInstanceOfFalse
+  abstract member-signature operator ==(dynamic other) → core::bool*; -> core::Object::==
+  abstract member-signature get hashCode() → core::int*; -> core::Object::hashCode
+  abstract member-signature method toString() → core::String*; -> core::Object::toString
+  abstract member-signature method noSuchMethod(core::Invocation* invocation) → dynamic; -> core::Object::noSuchMethod
+  abstract member-signature get runtimeType() → core::Type*; -> core::Object::runtimeType
+}
+static const field core::int* _private = #C2;
+
+constants  {
+  #C1 = 0
+  #C2 = 3
+  #C3 = 5
+  #C4 = iss::_A {field:#C3}
+}
diff --git a/pkg/front_end/testcases/general/issue31767.dart.textual_outline.expect b/pkg/front_end/testcases/general/issue31767.dart.textual_outline.expect
new file mode 100644
index 0000000..c0f1050
--- /dev/null
+++ b/pkg/front_end/testcases/general/issue31767.dart.textual_outline.expect
@@ -0,0 +1,21 @@
+// @dart = 2.9
+import 'issue31767_lib.dart';
+
+StringBuffer sb;
+
+class C {
+  final int w;
+  C.foo(int x, [int y = 0, int z = 0]) : w = p("x", x) + p("y", y) + p("z", z);
+}
+
+int p(String name, int value) {}
+mixin M on C {
+  int get w2 => w * w;
+}
+class D = C with M;
+mixin N on A {
+  int get w2 => w * w;
+}
+class E = A with N;
+main() {}
+expect(expected, actual) {}
diff --git a/pkg/front_end/testcases/general/issue31767.dart.textual_outline_modelled.expect b/pkg/front_end/testcases/general/issue31767.dart.textual_outline_modelled.expect
new file mode 100644
index 0000000..e349691
--- /dev/null
+++ b/pkg/front_end/testcases/general/issue31767.dart.textual_outline_modelled.expect
@@ -0,0 +1,21 @@
+// @dart = 2.9
+import 'issue31767_lib.dart';
+
+StringBuffer sb;
+
+class C {
+  C.foo(int x, [int y = 0, int z = 0]) : w = p("x", x) + p("y", y) + p("z", z);
+  final int w;
+}
+
+class D = C with M;
+class E = A with N;
+expect(expected, actual) {}
+int p(String name, int value) {}
+main() {}
+mixin M on C {
+  int get w2 => w * w;
+}
+mixin N on A {
+  int get w2 => w * w;
+}
diff --git a/pkg/front_end/testcases/general/issue31767_lib.dart b/pkg/front_end/testcases/general/issue31767_lib.dart
new file mode 100644
index 0000000..61406fd
--- /dev/null
+++ b/pkg/front_end/testcases/general/issue31767_lib.dart
@@ -0,0 +1,21 @@
+// Copyright (c) 2020, the Dart project authors.  Please see the AUTHORS file
+// for details. All rights reserved. Use of this source code is governed by a
+// BSD-style license that can be found in the LICENSE file.
+
+// @dart=2.9
+
+import 'issue31767.dart';
+
+const int _private = 3;
+
+class A {
+  final int w;
+  final _A a;
+  A.foo(int x, [int y = _private, int z = _private, this.a = const _A(5)])
+      : w = p("x", x) + p("y", y) + p("z", z);
+}
+
+class _A {
+  final int field;
+  const _A(this.field);
+}
diff --git a/pkg/front_end/testcases/general/issue37027.dart.strong.expect b/pkg/front_end/testcases/general/issue37027.dart.strong.expect
index 09fd889..d66702b 100644
--- a/pkg/front_end/testcases/general/issue37027.dart.strong.expect
+++ b/pkg/front_end/testcases/general/issue37027.dart.strong.expect
@@ -10,7 +10,7 @@
       final core::Set<core::int*>* #t1 = col::LinkedHashSet::•<core::int*>();
       for (core::int* e in ell)
         if(e.{core::int::isOdd})
-          #t1.{core::Set::add}(2.{core::num::*}(e));
+          #t1.{core::Set::add}{Invariant}(2.{core::num::*}(e));
     } =>#t1, super core::Object::•()
     ;
   abstract member-signature get _identityHashCode() → core::int*; -> core::Object::_identityHashCode
diff --git a/pkg/front_end/testcases/general/issue37027.dart.strong.transformed.expect b/pkg/front_end/testcases/general/issue37027.dart.strong.transformed.expect
index bc72e7f..fa88301 100644
--- a/pkg/front_end/testcases/general/issue37027.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/general/issue37027.dart.strong.transformed.expect
@@ -13,7 +13,7 @@
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           core::int* e = :sync-for-iterator.{core::Iterator::current};
           if(e.{core::int::isOdd})
-            #t1.{core::Set::add}(2.{core::num::*}(e));
+            #t1.{core::Set::add}{Invariant}(2.{core::num::*}(e));
         }
       }
     } =>#t1, super core::Object::•()
diff --git a/pkg/front_end/testcases/general/null_aware_spread.dart.strong.expect b/pkg/front_end/testcases/general/null_aware_spread.dart.strong.expect
index b724b3a..bd5bf0d 100644
--- a/pkg/front_end/testcases/general/null_aware_spread.dart.strong.expect
+++ b/pkg/front_end/testcases/general/null_aware_spread.dart.strong.expect
@@ -6,31 +6,31 @@
 static method nullAwareListSpread(core::List<core::String*>* list) → dynamic {
   list = block {
     final core::List<core::String*>* #t1 = <core::String*>[];
-    #t1.{core::List::add}("foo");
+    #t1.{core::List::add}{Invariant}("foo");
     final core::Iterable<core::String*>* #t2 = list;
     if(!#t2.{core::Object::==}(null))
       for (final core::String* #t3 in #t2)
-        #t1.{core::List::add}(#t3);
+        #t1.{core::List::add}{Invariant}(#t3);
   } =>#t1;
 }
 static method nullAwareSetSpread(core::Set<core::String*>* set) → dynamic {
   set = block {
     final core::Set<core::String*>* #t4 = col::LinkedHashSet::•<core::String*>();
-    #t4.{core::Set::add}("foo");
+    #t4.{core::Set::add}{Invariant}("foo");
     final core::Iterable<core::String*>* #t5 = set;
     if(!#t5.{core::Object::==}(null))
       for (final core::String* #t6 in #t5)
-        #t4.{core::Set::add}(#t6);
+        #t4.{core::Set::add}{Invariant}(#t6);
   } =>#t4;
 }
 static method nullAwareMapSpread(core::Map<core::int*, core::String*>* map) → dynamic {
   map = block {
     final core::Map<core::int*, core::String*>* #t7 = <core::int*, core::String*>{};
-    #t7.{core::Map::[]=}(0, "foo");
+    #t7.{core::Map::[]=}{Invariant}(0, "foo");
     final core::Map<core::int*, core::String*>* #t8 = map;
     if(!#t8.{core::Object::==}(null))
       for (final core::MapEntry<core::int*, core::String*>* #t9 in #t8.{core::Map::entries})
-        #t7.{core::Map::[]=}(#t9.{core::MapEntry::key}, #t9.{core::MapEntry::value});
+        #t7.{core::Map::[]=}{Invariant}(#t9.{core::MapEntry::key}, #t9.{core::MapEntry::value});
   } =>#t7;
 }
 static method main() → dynamic {
diff --git a/pkg/front_end/testcases/general/null_aware_spread.dart.strong.transformed.expect b/pkg/front_end/testcases/general/null_aware_spread.dart.strong.transformed.expect
index 9ff4788..67a6d44 100644
--- a/pkg/front_end/testcases/general/null_aware_spread.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/general/null_aware_spread.dart.strong.transformed.expect
@@ -6,13 +6,13 @@
 static method nullAwareListSpread(core::List<core::String*>* list) → dynamic {
   list = block {
     final core::List<core::String*>* #t1 = <core::String*>[];
-    #t1.{core::List::add}("foo");
+    #t1.{core::List::add}{Invariant}("foo");
     final core::Iterable<core::String*>* #t2 = list;
     if(!#t2.{core::Object::==}(null)) {
       core::Iterator<core::String*>* :sync-for-iterator = #t2.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::String* #t3 = :sync-for-iterator.{core::Iterator::current};
-        #t1.{core::List::add}(#t3);
+        #t1.{core::List::add}{Invariant}(#t3);
       }
     }
   } =>#t1;
@@ -20,13 +20,13 @@
 static method nullAwareSetSpread(core::Set<core::String*>* set) → dynamic {
   set = block {
     final core::Set<core::String*>* #t4 = new col::_CompactLinkedHashSet::•<core::String*>();
-    #t4.{core::Set::add}("foo");
+    #t4.{core::Set::add}{Invariant}("foo");
     final core::Iterable<core::String*>* #t5 = set;
     if(!#t5.{core::Object::==}(null)) {
       core::Iterator<core::String*>* :sync-for-iterator = #t5.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::String* #t6 = :sync-for-iterator.{core::Iterator::current};
-        #t4.{core::Set::add}(#t6);
+        #t4.{core::Set::add}{Invariant}(#t6);
       }
     }
   } =>#t4;
@@ -34,13 +34,13 @@
 static method nullAwareMapSpread(core::Map<core::int*, core::String*>* map) → dynamic {
   map = block {
     final core::Map<core::int*, core::String*>* #t7 = <core::int*, core::String*>{};
-    #t7.{core::Map::[]=}(0, "foo");
+    #t7.{core::Map::[]=}{Invariant}(0, "foo");
     final core::Map<core::int*, core::String*>* #t8 = map;
     if(!#t8.{core::Object::==}(null)) {
       core::Iterator<core::MapEntry<core::int*, core::String*>>* :sync-for-iterator = #t8.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::int*, core::String*>* #t9 = :sync-for-iterator.{core::Iterator::current};
-        #t7.{core::Map::[]=}(#t9.{core::MapEntry::key}, #t9.{core::MapEntry::value});
+        #t7.{core::Map::[]=}{Invariant}(#t9.{core::MapEntry::key}, #t9.{core::MapEntry::value});
       }
     }
   } =>#t7;
diff --git a/pkg/front_end/testcases/general/spread_collection.dart.strong.expect b/pkg/front_end/testcases/general/spread_collection.dart.strong.expect
index 08204f6..45566e9 100644
--- a/pkg/front_end/testcases/general/spread_collection.dart.strong.expect
+++ b/pkg/front_end/testcases/general/spread_collection.dart.strong.expect
@@ -14,33 +14,33 @@
 static method main() → dynamic {
   final core::List<core::int*>* aList = block {
     final core::List<core::int*>* #t1 = <core::int*>[];
-    #t1.{core::List::add}(1);
+    #t1.{core::List::add}{Invariant}(1);
     for (final core::int* #t2 in <core::int*>[2])
-      #t1.{core::List::add}(#t2);
+      #t1.{core::List::add}{Invariant}(#t2);
     final core::Iterable<core::int*>* #t3 = <core::int*>[3];
     if(!#t3.{core::Object::==}(null))
       for (final core::int* #t4 in #t3)
-        #t1.{core::List::add}(#t4);
+        #t1.{core::List::add}{Invariant}(#t4);
   } =>#t1;
   final core::Map<core::int*, core::int*>* aMap = block {
     final core::Map<core::int*, core::int*>* #t5 = <core::int*, core::int*>{};
-    #t5.{core::Map::[]=}(1, 1);
+    #t5.{core::Map::[]=}{Invariant}(1, 1);
     for (final core::MapEntry<core::int*, core::int*>* #t6 in <core::int*, core::int*>{2: 2}.{core::Map::entries})
-      #t5.{core::Map::[]=}(#t6.{core::MapEntry::key}, #t6.{core::MapEntry::value});
+      #t5.{core::Map::[]=}{Invariant}(#t6.{core::MapEntry::key}, #t6.{core::MapEntry::value});
     final core::Map<core::int*, core::int*>* #t7 = <core::int*, core::int*>{3: 3};
     if(!#t7.{core::Object::==}(null))
       for (final core::MapEntry<core::int*, core::int*>* #t8 in #t7.{core::Map::entries})
-        #t5.{core::Map::[]=}(#t8.{core::MapEntry::key}, #t8.{core::MapEntry::value});
+        #t5.{core::Map::[]=}{Invariant}(#t8.{core::MapEntry::key}, #t8.{core::MapEntry::value});
   } =>#t5;
   final core::Set<core::int*>* aSet = block {
     final core::Set<core::int*>* #t9 = col::LinkedHashSet::•<core::int*>();
-    #t9.{core::Set::add}(1);
+    #t9.{core::Set::add}{Invariant}(1);
     for (final core::int* #t10 in <core::int*>[2])
-      #t9.{core::Set::add}(#t10);
+      #t9.{core::Set::add}{Invariant}(#t10);
     final core::Iterable<core::int*>* #t11 = <core::int*>[3];
     if(!#t11.{core::Object::==}(null))
       for (final core::int* #t12 in #t11)
-        #t9.{core::Set::add}(#t12);
+        #t9.{core::Set::add}{Invariant}(#t12);
   } =>#t9;
   final dynamic aSetOrMap = invalid-expression "pkg/front_end/testcases/general/spread_collection.dart:21:21: Error: Not enough type information to disambiguate between literal set and literal map.
 Try providing type arguments for the literal explicitly to disambiguate it.
diff --git a/pkg/front_end/testcases/general/spread_collection.dart.strong.transformed.expect b/pkg/front_end/testcases/general/spread_collection.dart.strong.transformed.expect
index 15ed3cf..d6d75a5 100644
--- a/pkg/front_end/testcases/general/spread_collection.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/general/spread_collection.dart.strong.transformed.expect
@@ -14,12 +14,12 @@
 static method main() → dynamic {
   final core::List<core::int*>* aList = block {
     final core::List<core::int*>* #t1 = <core::int*>[];
-    #t1.{core::List::add}(1);
+    #t1.{core::List::add}{Invariant}(1);
     {
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[2].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t2 = :sync-for-iterator.{core::Iterator::current};
-        #t1.{core::List::add}(#t2);
+        #t1.{core::List::add}{Invariant}(#t2);
       }
     }
     final core::Iterable<core::int*>* #t3 = <core::int*>[3];
@@ -27,18 +27,18 @@
       core::Iterator<core::int*>* :sync-for-iterator = #t3.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t4 = :sync-for-iterator.{core::Iterator::current};
-        #t1.{core::List::add}(#t4);
+        #t1.{core::List::add}{Invariant}(#t4);
       }
     }
   } =>#t1;
   final core::Map<core::int*, core::int*>* aMap = block {
     final core::Map<core::int*, core::int*>* #t5 = <core::int*, core::int*>{};
-    #t5.{core::Map::[]=}(1, 1);
+    #t5.{core::Map::[]=}{Invariant}(1, 1);
     {
       core::Iterator<core::MapEntry<core::int*, core::int*>>* :sync-for-iterator = <core::int*, core::int*>{2: 2}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::int*, core::int*>* #t6 = :sync-for-iterator.{core::Iterator::current};
-        #t5.{core::Map::[]=}(#t6.{core::MapEntry::key}, #t6.{core::MapEntry::value});
+        #t5.{core::Map::[]=}{Invariant}(#t6.{core::MapEntry::key}, #t6.{core::MapEntry::value});
       }
     }
     final core::Map<core::int*, core::int*>* #t7 = <core::int*, core::int*>{3: 3};
@@ -46,18 +46,18 @@
       core::Iterator<core::MapEntry<core::int*, core::int*>>* :sync-for-iterator = #t7.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::int*, core::int*>* #t8 = :sync-for-iterator.{core::Iterator::current};
-        #t5.{core::Map::[]=}(#t8.{core::MapEntry::key}, #t8.{core::MapEntry::value});
+        #t5.{core::Map::[]=}{Invariant}(#t8.{core::MapEntry::key}, #t8.{core::MapEntry::value});
       }
     }
   } =>#t5;
   final core::Set<core::int*>* aSet = block {
     final core::Set<core::int*>* #t9 = new col::_CompactLinkedHashSet::•<core::int*>();
-    #t9.{core::Set::add}(1);
+    #t9.{core::Set::add}{Invariant}(1);
     {
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[2].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t10 = :sync-for-iterator.{core::Iterator::current};
-        #t9.{core::Set::add}(#t10);
+        #t9.{core::Set::add}{Invariant}(#t10);
       }
     }
     final core::Iterable<core::int*>* #t11 = <core::int*>[3];
@@ -65,7 +65,7 @@
       core::Iterator<core::int*>* :sync-for-iterator = #t11.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t12 = :sync-for-iterator.{core::Iterator::current};
-        #t9.{core::Set::add}(#t12);
+        #t9.{core::Set::add}{Invariant}(#t12);
       }
     }
   } =>#t9;
diff --git a/pkg/front_end/testcases/general/spread_collection_inference.dart.strong.expect b/pkg/front_end/testcases/general/spread_collection_inference.dart.strong.expect
index beb5aad..e2acef4 100644
--- a/pkg/front_end/testcases/general/spread_collection_inference.dart.strong.expect
+++ b/pkg/front_end/testcases/general/spread_collection_inference.dart.strong.expect
@@ -112,68 +112,68 @@
   core::List<dynamic>* lhs10 = block {
     final core::List<dynamic>* #t1 = <dynamic>[];
     for (final dynamic #t2 in <dynamic>[])
-      #t1.{core::List::add}(#t2);
+      #t1.{core::List::add}{Invariant}(#t2);
   } =>#t1;
   core::Set<dynamic>* set10 = block {
     final core::Set<dynamic>* #t3 = col::LinkedHashSet::•<dynamic>();
     for (final dynamic #t4 in <dynamic>[])
-      #t3.{core::Set::add}(#t4);
+      #t3.{core::Set::add}{Invariant}(#t4);
   } =>#t3;
   core::Map<dynamic, dynamic>* map10 = block {
     final core::Map<dynamic, dynamic>* #t5 = <dynamic, dynamic>{};
     for (final core::MapEntry<dynamic, dynamic>* #t6 in <dynamic, dynamic>{}.{core::Map::entries})
-      #t5.{core::Map::[]=}(#t6.{core::MapEntry::key}, #t6.{core::MapEntry::value});
+      #t5.{core::Map::[]=}{Invariant}(#t6.{core::MapEntry::key}, #t6.{core::MapEntry::value});
   } =>#t5;
   core::Map<dynamic, dynamic>* map10ambiguous = block {
     final core::Map<dynamic, dynamic>* #t7 = <dynamic, dynamic>{};
     for (final core::MapEntry<dynamic, dynamic>* #t8 in <dynamic, dynamic>{}.{core::Map::entries})
-      #t7.{core::Map::[]=}(#t8.{core::MapEntry::key}, #t8.{core::MapEntry::value});
+      #t7.{core::Map::[]=}{Invariant}(#t8.{core::MapEntry::key}, #t8.{core::MapEntry::value});
   } =>#t7;
   core::List<core::int*>* lhs20 = block {
     final core::List<core::int*>* #t9 = <core::int*>[];
     for (final core::int* #t10 in spread)
-      #t9.{core::List::add}(#t10);
+      #t9.{core::List::add}{Invariant}(#t10);
   } =>#t9;
   core::Set<core::int*>* set20 = block {
     final core::Set<core::int*>* #t11 = col::LinkedHashSet::•<core::int*>();
     for (final core::int* #t12 in spread)
-      #t11.{core::Set::add}(#t12);
-    #t11.{core::Set::add}(42);
+      #t11.{core::Set::add}{Invariant}(#t12);
+    #t11.{core::Set::add}{Invariant}(42);
   } =>#t11;
   core::Set<core::int*>* set20ambiguous = block {
     final core::Set<core::int*>* #t13 = col::LinkedHashSet::•<core::int*>();
     for (final dynamic #t14 in spread) {
       final core::int* #t15 = #t14 as{TypeError} core::int*;
-      #t13.{core::Set::add}(#t15);
+      #t13.{core::Set::add}{Invariant}(#t15);
     }
   } =>#t13;
   core::Map<core::String*, core::int*>* map20 = block {
     final core::Map<core::String*, core::int*>* #t16 = <core::String*, core::int*>{};
     for (final core::MapEntry<core::String*, core::int*>* #t17 in mapSpread.{core::Map::entries})
-      #t16.{core::Map::[]=}(#t17.{core::MapEntry::key}, #t17.{core::MapEntry::value});
-    #t16.{core::Map::[]=}("baz", 42);
+      #t16.{core::Map::[]=}{Invariant}(#t17.{core::MapEntry::key}, #t17.{core::MapEntry::value});
+    #t16.{core::Map::[]=}{Invariant}("baz", 42);
   } =>#t16;
   core::Map<core::String*, core::int*>* map20ambiguous = block {
     final core::Map<core::String*, core::int*>* #t18 = <core::String*, core::int*>{};
     for (final core::MapEntry<core::String*, core::int*>* #t19 in mapSpread.{core::Map::entries})
-      #t18.{core::Map::[]=}(#t19.{core::MapEntry::key}, #t19.{core::MapEntry::value});
+      #t18.{core::Map::[]=}{Invariant}(#t19.{core::MapEntry::key}, #t19.{core::MapEntry::value});
   } =>#t18;
   core::List<dynamic>* lhs21 = block {
     final core::List<dynamic>* #t20 = <dynamic>[];
     for (final dynamic #t21 in (spread as dynamic) as{TypeError,ForDynamic} core::Iterable<dynamic>*)
-      #t20.{core::List::add}(#t21);
+      #t20.{core::List::add}{Invariant}(#t21);
   } =>#t20;
   core::Set<dynamic>* set21 = block {
     final core::Set<dynamic>* #t22 = col::LinkedHashSet::•<dynamic>();
     for (final dynamic #t23 in (spread as dynamic) as{TypeError,ForDynamic} core::Iterable<dynamic>*)
-      #t22.{core::Set::add}(#t23);
-    #t22.{core::Set::add}(42);
+      #t22.{core::Set::add}{Invariant}(#t23);
+    #t22.{core::Set::add}{Invariant}(42);
   } =>#t22;
   core::Map<dynamic, dynamic>* map21 = block {
     final core::Map<dynamic, dynamic>* #t24 = <dynamic, dynamic>{};
     for (final core::MapEntry<dynamic, dynamic>* #t25 in ((mapSpread as dynamic) as{TypeError,ForDynamic} core::Map<dynamic, dynamic>*).{core::Map::entries})
-      #t24.{core::Map::[]=}(#t25.{core::MapEntry::key}, #t25.{core::MapEntry::value});
-    #t24.{core::Map::[]=}("baz", 42);
+      #t24.{core::Map::[]=}{Invariant}(#t25.{core::MapEntry::key}, #t25.{core::MapEntry::value});
+    #t24.{core::Map::[]=}{Invariant}("baz", 42);
   } =>#t24;
   dynamic map21ambiguous = invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:64:28: Error: Not enough type information to disambiguate between literal set and literal map.
 Try providing type arguments for the literal explicitly to disambiguate it.
@@ -182,48 +182,48 @@
   core::List<core::int*>* lhs22 = block {
     final core::List<core::int*>* #t26 = <core::int*>[];
     for (final core::int* #t27 in <core::int*>[])
-      #t26.{core::List::add}(#t27);
+      #t26.{core::List::add}{Invariant}(#t27);
   } =>#t26;
   core::Set<core::int*>* set22 = block {
     final core::Set<core::int*>* #t28 = col::LinkedHashSet::•<core::int*>();
     for (final core::int* #t29 in <core::int*>[])
-      #t28.{core::Set::add}(#t29);
-    #t28.{core::Set::add}(42);
+      #t28.{core::Set::add}{Invariant}(#t29);
+    #t28.{core::Set::add}{Invariant}(42);
   } =>#t28;
   core::Set<core::int*>* set22ambiguous = block {
     final core::Set<core::int*>* #t30 = col::LinkedHashSet::•<core::int*>();
     for (final dynamic #t31 in <core::int*>[]) {
       final core::int* #t32 = #t31 as{TypeError} core::int*;
-      #t30.{core::Set::add}(#t32);
+      #t30.{core::Set::add}{Invariant}(#t32);
     }
   } =>#t30;
   core::Map<core::String*, core::int*>* map22 = block {
     final core::Map<core::String*, core::int*>* #t33 = <core::String*, core::int*>{};
     for (final core::MapEntry<core::String*, core::int*>* #t34 in <core::String*, core::int*>{}.{core::Map::entries})
-      #t33.{core::Map::[]=}(#t34.{core::MapEntry::key}, #t34.{core::MapEntry::value});
+      #t33.{core::Map::[]=}{Invariant}(#t34.{core::MapEntry::key}, #t34.{core::MapEntry::value});
   } =>#t33;
   core::List<core::List<core::int*>*>* lhs23 = block {
     final core::List<core::List<core::int*>*>* #t35 = <core::List<core::int*>*>[];
     for (final core::List<core::int*>* #t36 in <core::List<core::int*>*>[<core::int*>[]])
-      #t35.{core::List::add}(#t36);
+      #t35.{core::List::add}{Invariant}(#t36);
   } =>#t35;
   core::Set<core::List<core::int*>*>* set23 = block {
     final core::Set<core::List<core::int*>*>* #t37 = col::LinkedHashSet::•<core::List<core::int*>*>();
     for (final core::List<core::int*>* #t38 in <core::List<core::int*>*>[<core::int*>[]])
-      #t37.{core::Set::add}(#t38);
-    #t37.{core::Set::add}(<core::int*>[42]);
+      #t37.{core::Set::add}{Invariant}(#t38);
+    #t37.{core::Set::add}{Invariant}(<core::int*>[42]);
   } =>#t37;
   core::Set<core::List<core::int*>*>* set23ambiguous = block {
     final core::Set<core::List<core::int*>*>* #t39 = col::LinkedHashSet::•<core::List<core::int*>*>();
     for (final dynamic #t40 in <core::List<core::int*>*>[<core::int*>[]]) {
       final core::List<core::int*>* #t41 = #t40 as{TypeError} core::List<core::int*>*;
-      #t39.{core::Set::add}(#t41);
+      #t39.{core::Set::add}{Invariant}(#t41);
     }
   } =>#t39;
   core::Map<core::String*, core::List<core::int*>*>* map23 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t42 = <core::String*, core::List<core::int*>*>{};
     for (final core::MapEntry<core::String*, core::List<core::int*>*>* #t43 in <core::String*, core::List<core::int*>*>{"baz": <core::int*>[]}.{core::Map::entries})
-      #t42.{core::Map::[]=}(#t43.{core::MapEntry::key}, #t43.{core::MapEntry::value});
+      #t42.{core::Map::[]=}{Invariant}(#t43.{core::MapEntry::key}, #t43.{core::MapEntry::value});
   } =>#t42;
   dynamic map24ambiguous = invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:96:28: Error: Both Iterable and Map spread elements encountered in ambiguous literal.
   dynamic map24ambiguous = {...spread, ...mapSpread};
@@ -234,7 +234,7 @@
                                    ^" in ( block {
     final core::List<core::int*>* #t45 = <core::int*>[];
     for (final core::int* #t46 in spread)
-      #t45.{core::List::add}(#t46);
+      #t45.{core::List::add}{Invariant}(#t46);
   } =>#t45) as{TypeError} core::int*;
   core::int* set30 = let final<BottomType> #t47 = invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:100:36: Error: A value of type 'Set<int>' can't be assigned to a variable of type 'int'.
  - 'Set' is from 'dart:core'.
@@ -242,8 +242,8 @@
                                    ^" in ( block {
     final core::Set<core::int*>* #t48 = col::LinkedHashSet::•<core::int*>();
     for (final core::int* #t49 in spread)
-      #t48.{core::Set::add}(#t49);
-    #t48.{core::Set::add}(42);
+      #t48.{core::Set::add}{Invariant}(#t49);
+    #t48.{core::Set::add}{Invariant}(42);
   } =>#t48) as{TypeError} core::int*;
   core::int* set30ambiguous = let final<BottomType> #t50 = invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:103:7: Error: A value of type 'Set<int>' can't be assigned to a variable of type 'int'.
  - 'Set' is from 'dart:core'.
@@ -252,7 +252,7 @@
     final core::Set<core::int*>* #t51 = col::LinkedHashSet::•<core::int*>();
     for (final dynamic #t52 in spread) {
       final core::int* #t53 = #t52 as{TypeError} core::int*;
-      #t51.{core::Set::add}(#t53);
+      #t51.{core::Set::add}{Invariant}(#t53);
     }
   } =>#t51) as{TypeError} core::int*;
   core::int* map30 = let final<BottomType> #t54 = invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:106:7: Error: A value of type 'Map<String, int>' can't be assigned to a variable of type 'int'.
@@ -261,8 +261,8 @@
       ^" in ( block {
     final core::Map<core::String*, core::int*>* #t55 = <core::String*, core::int*>{};
     for (final core::MapEntry<core::String*, core::int*>* #t56 in mapSpread.{core::Map::entries})
-      #t55.{core::Map::[]=}(#t56.{core::MapEntry::key}, #t56.{core::MapEntry::value});
-    #t55.{core::Map::[]=}("baz", 42);
+      #t55.{core::Map::[]=}{Invariant}(#t56.{core::MapEntry::key}, #t56.{core::MapEntry::value});
+    #t55.{core::Map::[]=}{Invariant}("baz", 42);
   } =>#t55) as{TypeError} core::int*;
   core::int* map30ambiguous = let final<BottomType> #t57 = invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:109:7: Error: A value of type 'Map<String, int>' can't be assigned to a variable of type 'int'.
  - 'Map' is from 'dart:core'.
@@ -270,14 +270,14 @@
       ^" in ( block {
     final core::Map<core::String*, core::int*>* #t58 = <core::String*, core::int*>{};
     for (final core::MapEntry<core::String*, core::int*>* #t59 in mapSpread.{core::Map::entries})
-      #t58.{core::Map::[]=}(#t59.{core::MapEntry::key}, #t59.{core::MapEntry::value});
+      #t58.{core::Map::[]=}{Invariant}(#t59.{core::MapEntry::key}, #t59.{core::MapEntry::value});
   } =>#t58) as{TypeError} core::int*;
   core::List<dynamic>* lhs40 = <dynamic>[invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:111:38: Error: Unexpected type 'int' of a spread.  Expected 'dynamic' or an Iterable.
   List<dynamic> lhs40 = <dynamic>[...notSpreadInt];
                                      ^"];
   core::Set<dynamic>* set40 = block {
     final core::Set<dynamic>* #t60 = col::LinkedHashSet::•<dynamic>();
-    #t60.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:113:37: Error: Unexpected type 'int' of a spread.  Expected 'dynamic' or an Iterable.
+    #t60.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:113:37: Error: Unexpected type 'int' of a spread.  Expected 'dynamic' or an Iterable.
   Set<dynamic> set40 = <dynamic>{...notSpreadInt};
                                     ^");
   } =>#t60;
@@ -289,7 +289,7 @@
                                      ^"];
   core::Set<dynamic>* set50 = block {
     final core::Set<dynamic>* #t61 = col::LinkedHashSet::•<dynamic>();
-    #t61.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:119:37: Error: Unexpected type 'int Function()' of a spread.  Expected 'dynamic' or an Iterable.
+    #t61.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:119:37: Error: Unexpected type 'int Function()' of a spread.  Expected 'dynamic' or an Iterable.
   Set<dynamic> set50 = <dynamic>{...notSpreadFunction};
                                     ^");
   } =>#t61;
@@ -301,7 +301,7 @@
                                    ^"];
   core::Set<core::String*>* set60 = block {
     final core::Set<core::String*>* #t62 = col::LinkedHashSet::•<core::String*>();
-    #t62.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:125:35: Error: Can't assign spread elements of type 'int' to collection elements of type 'String'.
+    #t62.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:125:35: Error: Can't assign spread elements of type 'int' to collection elements of type 'String'.
   Set<String> set60 = <String>{...spread};
                                   ^");
   } =>#t62;
@@ -316,18 +316,18 @@
                              ^"];
   core::Set<core::int*>* set70 = block {
     final core::Set<core::int*>* #t63 = col::LinkedHashSet::•<core::int*>();
-    #t63.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:133:29: Error: Can't spread a value with static type 'Null'.
+    #t63.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:133:29: Error: Can't spread a value with static type 'Null'.
   Set<int> set70 = <int>{...null};
                             ^");
   } =>#t63;
   core::Set<dynamic>* set71ambiguous = block {
     final core::Set<dynamic>* #t64 = col::LinkedHashSet::•<dynamic>();
-    #t64.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:137:8: Error: Expected ',' before this.
+    #t64.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:137:8: Error: Expected ',' before this.
     ...null,
        ^");
     for (final dynamic #t65 in <dynamic>[]) {
       final dynamic #t66 = #t65 as{TypeError} dynamic;
-      #t64.{core::Set::add}(#t66);
+      #t64.{core::Set::add}{Invariant}(#t66);
     }
   } =>#t64;
   core::Map<core::String*, core::int*>* map70 = <core::String*, core::int*>{invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:142:45: Error: Can't spread a value with static type 'Null'.
@@ -338,14 +338,14 @@
     final core::Iterable<core::int*>* #t68 = null;
     if(!#t68.{core::Object::==}(null))
       for (final core::int* #t69 in #t68)
-        #t67.{core::List::add}(#t69);
+        #t67.{core::List::add}{Invariant}(#t69);
   } =>#t67;
   core::Set<core::int*>* set80 = block {
     final core::Set<core::int*>* #t70 = col::LinkedHashSet::•<core::int*>();
     final core::Iterable<core::int*>* #t71 = null;
     if(!#t71.{core::Object::==}(null))
       for (final core::int* #t72 in #t71)
-        #t70.{core::Set::add}(#t72);
+        #t70.{core::Set::add}{Invariant}(#t72);
   } =>#t70;
   core::Set<dynamic>* set81ambiguous = block {
     final core::Set<dynamic>* #t73 = col::LinkedHashSet::•<dynamic>();
@@ -353,11 +353,11 @@
     if(!#t74.{core::Object::==}(null))
       for (final dynamic #t75 in #t74) {
         final dynamic #t76 = #t75 as{TypeError} dynamic;
-        #t73.{core::Set::add}(#t76);
+        #t73.{core::Set::add}{Invariant}(#t76);
       }
     for (final dynamic #t77 in <dynamic>[]) {
       final dynamic #t78 = #t77 as{TypeError} dynamic;
-      #t73.{core::Set::add}(#t78);
+      #t73.{core::Set::add}{Invariant}(#t78);
     }
   } =>#t73;
   core::Map<core::String*, core::int*>* map80 = block {
@@ -365,18 +365,18 @@
     final core::Map<core::String*, core::int*>* #t80 = null;
     if(!#t80.{core::Object::==}(null))
       for (final core::MapEntry<core::String*, core::int*>* #t81 in #t80.{core::Map::entries})
-        #t79.{core::Map::[]=}(#t81.{core::MapEntry::key}, #t81.{core::MapEntry::value});
+        #t79.{core::Map::[]=}{Invariant}(#t81.{core::MapEntry::key}, #t81.{core::MapEntry::value});
   } =>#t79;
   core::Map<core::String*, core::int*>* map90 = block {
     final core::Map<core::String*, core::int*>* #t82 = <core::String*, core::int*>{};
     for (final core::MapEntry<core::String*, core::int*>* #t83 in self::bar<core::String*, core::int*>().{core::Map::entries})
-      #t82.{core::Map::[]=}(#t83.{core::MapEntry::key}, #t83.{core::MapEntry::value});
+      #t82.{core::Map::[]=}{Invariant}(#t83.{core::MapEntry::key}, #t83.{core::MapEntry::value});
   } =>#t82;
   core::List<core::int*>* list100 = block {
     final core::List<core::int*>* #t84 = <core::int*>[];
     for (final dynamic #t85 in listNum) {
       final core::int* #t86 = #t85 as{TypeError} core::int*;
-      #t84.{core::List::add}(#t86);
+      #t84.{core::List::add}{Invariant}(#t86);
     }
   } =>#t84;
   core::Map<core::num*, core::int*>* map100 = block {
@@ -384,14 +384,14 @@
     for (final core::MapEntry<dynamic, dynamic>* #t88 in mapIntNum.{core::Map::entries}) {
       final core::num* #t89 = #t88.{core::MapEntry::key} as{TypeError} core::num*;
       final core::int* #t90 = #t88.{core::MapEntry::value} as{TypeError} core::int*;
-      #t87.{core::Map::[]=}(#t89, #t90);
+      #t87.{core::Map::[]=}{Invariant}(#t89, #t90);
     }
   } =>#t87;
   core::List<core::int*>* list110 = block {
     final core::List<core::int*>* #t91 = <core::int*>[];
     for (final dynamic #t92 in dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*) {
       final core::int* #t93 = #t92 as{TypeError} core::int*;
-      #t91.{core::List::add}(#t93);
+      #t91.{core::List::add}{Invariant}(#t93);
     }
   } =>#t91;
   core::Map<core::num*, core::int*>* map110 = block {
@@ -399,7 +399,7 @@
     for (final core::MapEntry<dynamic, dynamic>* #t95 in (dynVar as{TypeError,ForDynamic} core::Map<dynamic, dynamic>*).{core::Map::entries}) {
       final core::num* #t96 = #t95.{core::MapEntry::key} as{TypeError} core::num*;
       final core::int* #t97 = #t95.{core::MapEntry::value} as{TypeError} core::int*;
-      #t94.{core::Map::[]=}(#t96, #t97);
+      #t94.{core::Map::[]=}{Invariant}(#t96, #t97);
     }
   } =>#t94;
 }
diff --git a/pkg/front_end/testcases/general/spread_collection_inference.dart.strong.transformed.expect b/pkg/front_end/testcases/general/spread_collection_inference.dart.strong.transformed.expect
index 5652fe4..6ecdd84 100644
--- a/pkg/front_end/testcases/general/spread_collection_inference.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/general/spread_collection_inference.dart.strong.transformed.expect
@@ -115,7 +115,7 @@
       core::Iterator<dynamic>* :sync-for-iterator = <dynamic>[].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final dynamic #t2 = :sync-for-iterator.{core::Iterator::current};
-        #t1.{core::List::add}(#t2);
+        #t1.{core::List::add}{Invariant}(#t2);
       }
     }
   } =>#t1;
@@ -125,7 +125,7 @@
       core::Iterator<dynamic>* :sync-for-iterator = <dynamic>[].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final dynamic #t4 = :sync-for-iterator.{core::Iterator::current};
-        #t3.{core::Set::add}(#t4);
+        #t3.{core::Set::add}{Invariant}(#t4);
       }
     }
   } =>#t3;
@@ -135,7 +135,7 @@
       core::Iterator<core::MapEntry<dynamic, dynamic>>* :sync-for-iterator = <dynamic, dynamic>{}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<dynamic, dynamic>* #t6 = :sync-for-iterator.{core::Iterator::current};
-        #t5.{core::Map::[]=}(#t6.{core::MapEntry::key}, #t6.{core::MapEntry::value});
+        #t5.{core::Map::[]=}{Invariant}(#t6.{core::MapEntry::key}, #t6.{core::MapEntry::value});
       }
     }
   } =>#t5;
@@ -145,7 +145,7 @@
       core::Iterator<core::MapEntry<dynamic, dynamic>>* :sync-for-iterator = <dynamic, dynamic>{}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<dynamic, dynamic>* #t8 = :sync-for-iterator.{core::Iterator::current};
-        #t7.{core::Map::[]=}(#t8.{core::MapEntry::key}, #t8.{core::MapEntry::value});
+        #t7.{core::Map::[]=}{Invariant}(#t8.{core::MapEntry::key}, #t8.{core::MapEntry::value});
       }
     }
   } =>#t7;
@@ -155,7 +155,7 @@
       core::Iterator<core::int*>* :sync-for-iterator = spread.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t10 = :sync-for-iterator.{core::Iterator::current};
-        #t9.{core::List::add}(#t10);
+        #t9.{core::List::add}{Invariant}(#t10);
       }
     }
   } =>#t9;
@@ -165,10 +165,10 @@
       core::Iterator<core::int*>* :sync-for-iterator = spread.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t12 = :sync-for-iterator.{core::Iterator::current};
-        #t11.{core::Set::add}(#t12);
+        #t11.{core::Set::add}{Invariant}(#t12);
       }
     }
-    #t11.{core::Set::add}(42);
+    #t11.{core::Set::add}{Invariant}(42);
   } =>#t11;
   core::Set<core::int*>* set20ambiguous = block {
     final core::Set<core::int*>* #t13 = new col::_CompactLinkedHashSet::•<core::int*>();
@@ -178,7 +178,7 @@
         final dynamic #t14 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int* #t15 = #t14 as{TypeError} core::int*;
-          #t13.{core::Set::add}(#t15);
+          #t13.{core::Set::add}{Invariant}(#t15);
         }
       }
     }
@@ -189,10 +189,10 @@
       core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = mapSpread.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::int*>* #t17 = :sync-for-iterator.{core::Iterator::current};
-        #t16.{core::Map::[]=}(#t17.{core::MapEntry::key}, #t17.{core::MapEntry::value});
+        #t16.{core::Map::[]=}{Invariant}(#t17.{core::MapEntry::key}, #t17.{core::MapEntry::value});
       }
     }
-    #t16.{core::Map::[]=}("baz", 42);
+    #t16.{core::Map::[]=}{Invariant}("baz", 42);
   } =>#t16;
   core::Map<core::String*, core::int*>* map20ambiguous = block {
     final core::Map<core::String*, core::int*>* #t18 = <core::String*, core::int*>{};
@@ -200,7 +200,7 @@
       core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = mapSpread.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::int*>* #t19 = :sync-for-iterator.{core::Iterator::current};
-        #t18.{core::Map::[]=}(#t19.{core::MapEntry::key}, #t19.{core::MapEntry::value});
+        #t18.{core::Map::[]=}{Invariant}(#t19.{core::MapEntry::key}, #t19.{core::MapEntry::value});
       }
     }
   } =>#t18;
@@ -210,7 +210,7 @@
       core::Iterator<dynamic>* :sync-for-iterator = ((spread as dynamic) as{TypeError,ForDynamic} core::Iterable<dynamic>*).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final dynamic #t21 = :sync-for-iterator.{core::Iterator::current};
-        #t20.{core::List::add}(#t21);
+        #t20.{core::List::add}{Invariant}(#t21);
       }
     }
   } =>#t20;
@@ -220,10 +220,10 @@
       core::Iterator<dynamic>* :sync-for-iterator = ((spread as dynamic) as{TypeError,ForDynamic} core::Iterable<dynamic>*).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final dynamic #t23 = :sync-for-iterator.{core::Iterator::current};
-        #t22.{core::Set::add}(#t23);
+        #t22.{core::Set::add}{Invariant}(#t23);
       }
     }
-    #t22.{core::Set::add}(42);
+    #t22.{core::Set::add}{Invariant}(42);
   } =>#t22;
   core::Map<dynamic, dynamic>* map21 = block {
     final core::Map<dynamic, dynamic>* #t24 = <dynamic, dynamic>{};
@@ -231,10 +231,10 @@
       core::Iterator<core::MapEntry<dynamic, dynamic>>* :sync-for-iterator = ((mapSpread as dynamic) as{TypeError,ForDynamic} core::Map<dynamic, dynamic>*).{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<dynamic, dynamic>* #t25 = :sync-for-iterator.{core::Iterator::current};
-        #t24.{core::Map::[]=}(#t25.{core::MapEntry::key}, #t25.{core::MapEntry::value});
+        #t24.{core::Map::[]=}{Invariant}(#t25.{core::MapEntry::key}, #t25.{core::MapEntry::value});
       }
     }
-    #t24.{core::Map::[]=}("baz", 42);
+    #t24.{core::Map::[]=}{Invariant}("baz", 42);
   } =>#t24;
   dynamic map21ambiguous = invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:64:28: Error: Not enough type information to disambiguate between literal set and literal map.
 Try providing type arguments for the literal explicitly to disambiguate it.
@@ -246,7 +246,7 @@
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t27 = :sync-for-iterator.{core::Iterator::current};
-        #t26.{core::List::add}(#t27);
+        #t26.{core::List::add}{Invariant}(#t27);
       }
     }
   } =>#t26;
@@ -256,10 +256,10 @@
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t29 = :sync-for-iterator.{core::Iterator::current};
-        #t28.{core::Set::add}(#t29);
+        #t28.{core::Set::add}{Invariant}(#t29);
       }
     }
-    #t28.{core::Set::add}(42);
+    #t28.{core::Set::add}{Invariant}(42);
   } =>#t28;
   core::Set<core::int*>* set22ambiguous = block {
     final core::Set<core::int*>* #t30 = new col::_CompactLinkedHashSet::•<core::int*>();
@@ -269,7 +269,7 @@
         final dynamic #t31 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int* #t32 = #t31 as{TypeError} core::int*;
-          #t30.{core::Set::add}(#t32);
+          #t30.{core::Set::add}{Invariant}(#t32);
         }
       }
     }
@@ -280,7 +280,7 @@
       core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = <core::String*, core::int*>{}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::int*>* #t34 = :sync-for-iterator.{core::Iterator::current};
-        #t33.{core::Map::[]=}(#t34.{core::MapEntry::key}, #t34.{core::MapEntry::value});
+        #t33.{core::Map::[]=}{Invariant}(#t34.{core::MapEntry::key}, #t34.{core::MapEntry::value});
       }
     }
   } =>#t33;
@@ -290,7 +290,7 @@
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t36 = :sync-for-iterator.{core::Iterator::current};
-        #t35.{core::List::add}(#t36);
+        #t35.{core::List::add}{Invariant}(#t36);
       }
     }
   } =>#t35;
@@ -300,10 +300,10 @@
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t38 = :sync-for-iterator.{core::Iterator::current};
-        #t37.{core::Set::add}(#t38);
+        #t37.{core::Set::add}{Invariant}(#t38);
       }
     }
-    #t37.{core::Set::add}(<core::int*>[42]);
+    #t37.{core::Set::add}{Invariant}(<core::int*>[42]);
   } =>#t37;
   core::Set<core::List<core::int*>*>* set23ambiguous = block {
     final core::Set<core::List<core::int*>*>* #t39 = new col::_CompactLinkedHashSet::•<core::List<core::int*>*>();
@@ -313,7 +313,7 @@
         final dynamic #t40 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::List<core::int*>* #t41 = #t40 as{TypeError} core::List<core::int*>*;
-          #t39.{core::Set::add}(#t41);
+          #t39.{core::Set::add}{Invariant}(#t41);
         }
       }
     }
@@ -324,7 +324,7 @@
       core::Iterator<core::MapEntry<core::String*, core::List<core::int*>*>>* :sync-for-iterator = <core::String*, core::List<core::int*>*>{"baz": <core::int*>[]}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::List<core::int*>*>* #t43 = :sync-for-iterator.{core::Iterator::current};
-        #t42.{core::Map::[]=}(#t43.{core::MapEntry::key}, #t43.{core::MapEntry::value});
+        #t42.{core::Map::[]=}{Invariant}(#t43.{core::MapEntry::key}, #t43.{core::MapEntry::value});
       }
     }
   } =>#t42;
@@ -340,7 +340,7 @@
       core::Iterator<core::int*>* :sync-for-iterator = spread.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t46 = :sync-for-iterator.{core::Iterator::current};
-        #t45.{core::List::add}(#t46);
+        #t45.{core::List::add}{Invariant}(#t46);
       }
     }
   } =>#t45) as{TypeError} core::int*;
@@ -353,10 +353,10 @@
       core::Iterator<core::int*>* :sync-for-iterator = spread.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t49 = :sync-for-iterator.{core::Iterator::current};
-        #t48.{core::Set::add}(#t49);
+        #t48.{core::Set::add}{Invariant}(#t49);
       }
     }
-    #t48.{core::Set::add}(42);
+    #t48.{core::Set::add}{Invariant}(42);
   } =>#t48) as{TypeError} core::int*;
   core::int* set30ambiguous = let final<BottomType> #t50 = invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:103:7: Error: A value of type 'Set<int>' can't be assigned to a variable of type 'int'.
  - 'Set' is from 'dart:core'.
@@ -369,7 +369,7 @@
         final dynamic #t52 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int* #t53 = #t52 as{TypeError} core::int*;
-          #t51.{core::Set::add}(#t53);
+          #t51.{core::Set::add}{Invariant}(#t53);
         }
       }
     }
@@ -383,10 +383,10 @@
       core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = mapSpread.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::int*>* #t56 = :sync-for-iterator.{core::Iterator::current};
-        #t55.{core::Map::[]=}(#t56.{core::MapEntry::key}, #t56.{core::MapEntry::value});
+        #t55.{core::Map::[]=}{Invariant}(#t56.{core::MapEntry::key}, #t56.{core::MapEntry::value});
       }
     }
-    #t55.{core::Map::[]=}("baz", 42);
+    #t55.{core::Map::[]=}{Invariant}("baz", 42);
   } =>#t55) as{TypeError} core::int*;
   core::int* map30ambiguous = let final<BottomType> #t57 = invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:109:7: Error: A value of type 'Map<String, int>' can't be assigned to a variable of type 'int'.
  - 'Map' is from 'dart:core'.
@@ -397,7 +397,7 @@
       core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = mapSpread.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::int*>* #t59 = :sync-for-iterator.{core::Iterator::current};
-        #t58.{core::Map::[]=}(#t59.{core::MapEntry::key}, #t59.{core::MapEntry::value});
+        #t58.{core::Map::[]=}{Invariant}(#t59.{core::MapEntry::key}, #t59.{core::MapEntry::value});
       }
     }
   } =>#t58) as{TypeError} core::int*;
@@ -406,7 +406,7 @@
                                      ^"];
   core::Set<dynamic>* set40 = block {
     final core::Set<dynamic>* #t60 = new col::_CompactLinkedHashSet::•<dynamic>();
-    #t60.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:113:37: Error: Unexpected type 'int' of a spread.  Expected 'dynamic' or an Iterable.
+    #t60.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:113:37: Error: Unexpected type 'int' of a spread.  Expected 'dynamic' or an Iterable.
   Set<dynamic> set40 = <dynamic>{...notSpreadInt};
                                     ^");
   } =>#t60;
@@ -418,7 +418,7 @@
                                      ^"];
   core::Set<dynamic>* set50 = block {
     final core::Set<dynamic>* #t61 = new col::_CompactLinkedHashSet::•<dynamic>();
-    #t61.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:119:37: Error: Unexpected type 'int Function()' of a spread.  Expected 'dynamic' or an Iterable.
+    #t61.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:119:37: Error: Unexpected type 'int Function()' of a spread.  Expected 'dynamic' or an Iterable.
   Set<dynamic> set50 = <dynamic>{...notSpreadFunction};
                                     ^");
   } =>#t61;
@@ -430,7 +430,7 @@
                                    ^"];
   core::Set<core::String*>* set60 = block {
     final core::Set<core::String*>* #t62 = new col::_CompactLinkedHashSet::•<core::String*>();
-    #t62.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:125:35: Error: Can't assign spread elements of type 'int' to collection elements of type 'String'.
+    #t62.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:125:35: Error: Can't assign spread elements of type 'int' to collection elements of type 'String'.
   Set<String> set60 = <String>{...spread};
                                   ^");
   } =>#t62;
@@ -445,13 +445,13 @@
                              ^"];
   core::Set<core::int*>* set70 = block {
     final core::Set<core::int*>* #t63 = new col::_CompactLinkedHashSet::•<core::int*>();
-    #t63.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:133:29: Error: Can't spread a value with static type 'Null'.
+    #t63.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:133:29: Error: Can't spread a value with static type 'Null'.
   Set<int> set70 = <int>{...null};
                             ^");
   } =>#t63;
   core::Set<dynamic>* set71ambiguous = block {
     final core::Set<dynamic>* #t64 = new col::_CompactLinkedHashSet::•<dynamic>();
-    #t64.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:137:8: Error: Expected ',' before this.
+    #t64.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general/spread_collection_inference.dart:137:8: Error: Expected ',' before this.
     ...null,
        ^");
     {
@@ -460,7 +460,7 @@
         final dynamic #t65 = :sync-for-iterator.{core::Iterator::current};
         {
           final dynamic #t66 = #t65 as{TypeError} dynamic;
-          #t64.{core::Set::add}(#t66);
+          #t64.{core::Set::add}{Invariant}(#t66);
         }
       }
     }
@@ -475,7 +475,7 @@
       core::Iterator<core::int*>* :sync-for-iterator = #t68.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t69 = :sync-for-iterator.{core::Iterator::current};
-        #t67.{core::List::add}(#t69);
+        #t67.{core::List::add}{Invariant}(#t69);
       }
     }
   } =>#t67;
@@ -486,7 +486,7 @@
       core::Iterator<core::int*>* :sync-for-iterator = #t71.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t72 = :sync-for-iterator.{core::Iterator::current};
-        #t70.{core::Set::add}(#t72);
+        #t70.{core::Set::add}{Invariant}(#t72);
       }
     }
   } =>#t70;
@@ -499,7 +499,7 @@
         final dynamic #t75 = :sync-for-iterator.{core::Iterator::current};
         {
           final dynamic #t76 = #t75 as{TypeError} dynamic;
-          #t73.{core::Set::add}(#t76);
+          #t73.{core::Set::add}{Invariant}(#t76);
         }
       }
     }
@@ -509,7 +509,7 @@
         final dynamic #t77 = :sync-for-iterator.{core::Iterator::current};
         {
           final dynamic #t78 = #t77 as{TypeError} dynamic;
-          #t73.{core::Set::add}(#t78);
+          #t73.{core::Set::add}{Invariant}(#t78);
         }
       }
     }
@@ -521,7 +521,7 @@
       core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = #t80.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::int*>* #t81 = :sync-for-iterator.{core::Iterator::current};
-        #t79.{core::Map::[]=}(#t81.{core::MapEntry::key}, #t81.{core::MapEntry::value});
+        #t79.{core::Map::[]=}{Invariant}(#t81.{core::MapEntry::key}, #t81.{core::MapEntry::value});
       }
     }
   } =>#t79;
@@ -531,7 +531,7 @@
       core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = self::bar<core::String*, core::int*>().{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::int*>* #t83 = :sync-for-iterator.{core::Iterator::current};
-        #t82.{core::Map::[]=}(#t83.{core::MapEntry::key}, #t83.{core::MapEntry::value});
+        #t82.{core::Map::[]=}{Invariant}(#t83.{core::MapEntry::key}, #t83.{core::MapEntry::value});
       }
     }
   } =>#t82;
@@ -543,7 +543,7 @@
         final dynamic #t85 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int* #t86 = #t85 as{TypeError} core::int*;
-          #t84.{core::List::add}(#t86);
+          #t84.{core::List::add}{Invariant}(#t86);
         }
       }
     }
@@ -557,7 +557,7 @@
         {
           final core::num* #t89 = #t88.{core::MapEntry::key} as{TypeError} core::num*;
           final core::int* #t90 = #t88.{core::MapEntry::value} as{TypeError} core::int*;
-          #t87.{core::Map::[]=}(#t89, #t90);
+          #t87.{core::Map::[]=}{Invariant}(#t89, #t90);
         }
       }
     }
@@ -570,7 +570,7 @@
         final dynamic #t92 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int* #t93 = #t92 as{TypeError} core::int*;
-          #t91.{core::List::add}(#t93);
+          #t91.{core::List::add}{Invariant}(#t93);
         }
       }
     }
@@ -584,7 +584,7 @@
         {
           final core::num* #t96 = #t95.{core::MapEntry::key} as{TypeError} core::num*;
           final core::int* #t97 = #t95.{core::MapEntry::value} as{TypeError} core::int*;
-          #t94.{core::Map::[]=}(#t96, #t97);
+          #t94.{core::Map::[]=}{Invariant}(#t96, #t97);
         }
       }
     }
diff --git a/pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection.dart.weak.expect b/pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection.dart.weak.expect
index 3044135..dffdbc4 100644
--- a/pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection.dart.weak.expect
+++ b/pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection.dart.weak.expect
@@ -6,63 +6,63 @@
 static method main() → dynamic {
   final core::List<core::int*>* aList = block {
     final core::List<core::int*>* #t1 = <core::int*>[];
-    #t1.{core::List::add}(1);
+    #t1.{core::List::add}{Invariant}(1);
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-      #t1.{core::List::add}(2);
+      #t1.{core::List::add}{Invariant}(2);
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-      #t1.{core::List::add}(3);
+      #t1.{core::List::add}{Invariant}(3);
     else
-      #t1.{core::List::add}(1.{core::int::unary-}());
+      #t1.{core::List::add}{Invariant}(1.{core::int::unary-}());
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
       if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-        #t1.{core::List::add}(4);
+        #t1.{core::List::add}{Invariant}(4);
     for (core::int* i in <core::int*>[5, 6, 7])
-      #t1.{core::List::add}(i);
+      #t1.{core::List::add}{Invariant}(i);
     for (core::int* i in <core::int*>[8, 9, 10])
       if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-        #t1.{core::List::add}(i);
+        #t1.{core::List::add}{Invariant}(i);
     for (core::int* i = 11; i.{core::num::<=}(14); i = i.{core::num::+}(1))
-      #t1.{core::List::add}(i);
+      #t1.{core::List::add}{Invariant}(i);
   } =>#t1;
   final core::Set<core::int*>* aSet = block {
     final core::Set<core::int*>* #t2 = col::LinkedHashSet::•<core::int*>();
-    #t2.{core::Set::add}(1);
+    #t2.{core::Set::add}{Invariant}(1);
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-      #t2.{core::Set::add}(2);
+      #t2.{core::Set::add}{Invariant}(2);
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-      #t2.{core::Set::add}(3);
+      #t2.{core::Set::add}{Invariant}(3);
     else
-      #t2.{core::Set::add}(1.{core::int::unary-}());
+      #t2.{core::Set::add}{Invariant}(1.{core::int::unary-}());
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
       if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-        #t2.{core::Set::add}(4);
+        #t2.{core::Set::add}{Invariant}(4);
     for (core::int* i in <core::int*>[5, 6, 7])
-      #t2.{core::Set::add}(i);
+      #t2.{core::Set::add}{Invariant}(i);
     for (core::int* i in <core::int*>[8, 9, 10])
       if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-        #t2.{core::Set::add}(i);
+        #t2.{core::Set::add}{Invariant}(i);
     for (core::int* i = 11; i.{core::num::<=}(14); i = i.{core::num::+}(1))
-      #t2.{core::Set::add}(i);
+      #t2.{core::Set::add}{Invariant}(i);
   } =>#t2;
   final core::Map<core::int*, core::int*>* aMap = block {
     final core::Map<core::int*, core::int*>* #t3 = <core::int*, core::int*>{};
-    #t3.{core::Map::[]=}(1, 1);
+    #t3.{core::Map::[]=}{Invariant}(1, 1);
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-      #t3.{core::Map::[]=}(2, 2);
+      #t3.{core::Map::[]=}{Invariant}(2, 2);
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-      #t3.{core::Map::[]=}(3, 3);
+      #t3.{core::Map::[]=}{Invariant}(3, 3);
     else
-      #t3.{core::Map::[]=}(1.{core::int::unary-}(), 1.{core::int::unary-}());
+      #t3.{core::Map::[]=}{Invariant}(1.{core::int::unary-}(), 1.{core::int::unary-}());
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
       if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-        #t3.{core::Map::[]=}(4, 4);
+        #t3.{core::Map::[]=}{Invariant}(4, 4);
     for (core::int* i in <core::int*>[5, 6, 7])
-      #t3.{core::Map::[]=}(i, i);
+      #t3.{core::Map::[]=}{Invariant}(i, i);
     for (core::int* i in <core::int*>[8, 9, 10])
       if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-        #t3.{core::Map::[]=}(i, i);
+        #t3.{core::Map::[]=}{Invariant}(i, i);
     for (core::int* i = 11; i.{core::num::<=}(14); i = i.{core::num::+}(1))
-      #t3.{core::Map::[]=}(i, i);
+      #t3.{core::Map::[]=}{Invariant}(i, i);
   } =>#t3;
   core::print(aList);
   core::print(aSet);
diff --git a/pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection.dart.weak.transformed.expect b/pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection.dart.weak.transformed.expect
index fa89fde..c62af95 100644
--- a/pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection.dart.weak.transformed.expect
@@ -6,21 +6,21 @@
 static method main() → dynamic {
   final core::List<core::int*>* aList = block {
     final core::List<core::int*>* #t1 = <core::int*>[];
-    #t1.{core::List::add}(1);
+    #t1.{core::List::add}{Invariant}(1);
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-      #t1.{core::List::add}(2);
+      #t1.{core::List::add}{Invariant}(2);
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-      #t1.{core::List::add}(3);
+      #t1.{core::List::add}{Invariant}(3);
     else
-      #t1.{core::List::add}(1.{core::int::unary-}());
+      #t1.{core::List::add}{Invariant}(1.{core::int::unary-}());
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
       if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-        #t1.{core::List::add}(4);
+        #t1.{core::List::add}{Invariant}(4);
     {
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[5, 6, 7].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         core::int* i = :sync-for-iterator.{core::Iterator::current};
-        #t1.{core::List::add}(i);
+        #t1.{core::List::add}{Invariant}(i);
       }
     }
     {
@@ -28,29 +28,29 @@
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         core::int* i = :sync-for-iterator.{core::Iterator::current};
         if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-          #t1.{core::List::add}(i);
+          #t1.{core::List::add}{Invariant}(i);
       }
     }
     for (core::int* i = 11; i.{core::num::<=}(14); i = i.{core::num::+}(1))
-      #t1.{core::List::add}(i);
+      #t1.{core::List::add}{Invariant}(i);
   } =>#t1;
   final core::Set<core::int*>* aSet = block {
     final core::Set<core::int*>* #t2 = new col::_CompactLinkedHashSet::•<core::int*>();
-    #t2.{core::Set::add}(1);
+    #t2.{core::Set::add}{Invariant}(1);
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-      #t2.{core::Set::add}(2);
+      #t2.{core::Set::add}{Invariant}(2);
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-      #t2.{core::Set::add}(3);
+      #t2.{core::Set::add}{Invariant}(3);
     else
-      #t2.{core::Set::add}(1.{core::int::unary-}());
+      #t2.{core::Set::add}{Invariant}(1.{core::int::unary-}());
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
       if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-        #t2.{core::Set::add}(4);
+        #t2.{core::Set::add}{Invariant}(4);
     {
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[5, 6, 7].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         core::int* i = :sync-for-iterator.{core::Iterator::current};
-        #t2.{core::Set::add}(i);
+        #t2.{core::Set::add}{Invariant}(i);
       }
     }
     {
@@ -58,29 +58,29 @@
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         core::int* i = :sync-for-iterator.{core::Iterator::current};
         if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-          #t2.{core::Set::add}(i);
+          #t2.{core::Set::add}{Invariant}(i);
       }
     }
     for (core::int* i = 11; i.{core::num::<=}(14); i = i.{core::num::+}(1))
-      #t2.{core::Set::add}(i);
+      #t2.{core::Set::add}{Invariant}(i);
   } =>#t2;
   final core::Map<core::int*, core::int*>* aMap = block {
     final core::Map<core::int*, core::int*>* #t3 = <core::int*, core::int*>{};
-    #t3.{core::Map::[]=}(1, 1);
+    #t3.{core::Map::[]=}{Invariant}(1, 1);
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-      #t3.{core::Map::[]=}(2, 2);
+      #t3.{core::Map::[]=}{Invariant}(2, 2);
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-      #t3.{core::Map::[]=}(3, 3);
+      #t3.{core::Map::[]=}{Invariant}(3, 3);
     else
-      #t3.{core::Map::[]=}(1.{core::int::unary-}(), 1.{core::int::unary-}());
+      #t3.{core::Map::[]=}{Invariant}(1.{core::int::unary-}(), 1.{core::int::unary-}());
     if(self::oracle() as{TypeError,ForDynamic} core::bool*)
       if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-        #t3.{core::Map::[]=}(4, 4);
+        #t3.{core::Map::[]=}{Invariant}(4, 4);
     {
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[5, 6, 7].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         core::int* i = :sync-for-iterator.{core::Iterator::current};
-        #t3.{core::Map::[]=}(i, i);
+        #t3.{core::Map::[]=}{Invariant}(i, i);
       }
     }
     {
@@ -88,11 +88,11 @@
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         core::int* i = :sync-for-iterator.{core::Iterator::current};
         if(self::oracle() as{TypeError,ForDynamic} core::bool*)
-          #t3.{core::Map::[]=}(i, i);
+          #t3.{core::Map::[]=}{Invariant}(i, i);
       }
     }
     for (core::int* i = 11; i.{core::num::<=}(14); i = i.{core::num::+}(1))
-      #t3.{core::Map::[]=}(i, i);
+      #t3.{core::Map::[]=}{Invariant}(i, i);
   } =>#t3;
   core::print(aList);
   core::print(aSet);
diff --git a/pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart.weak.expect b/pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart.weak.expect
index a8cfc9f..9301e7e 100644
--- a/pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart.weak.expect
+++ b/pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart.weak.expect
@@ -454,195 +454,195 @@
   core::List<core::int*>* list10 = block {
     final core::List<core::int*>* #t1 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t1.{core::List::add}(42);
+      #t1.{core::List::add}{Invariant}(42);
   } =>#t1;
   core::Set<core::int*>* set10 = block {
     final core::Set<core::int*>* #t2 = col::LinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t2.{core::Set::add}(42);
-    #t2.{core::Set::add}(null);
+      #t2.{core::Set::add}{Invariant}(42);
+    #t2.{core::Set::add}{Invariant}(null);
   } =>#t2;
   core::Map<core::String*, core::int*>* map10 = block {
     final core::Map<core::String*, core::int*>* #t3 = <core::String*, core::int*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t3.{core::Map::[]=}("bar", 42);
-    #t3.{core::Map::[]=}("baz", null);
+      #t3.{core::Map::[]=}{Invariant}("bar", 42);
+    #t3.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t3;
   core::List<dynamic>* list11 = block {
     final core::List<dynamic>* #t4 = <dynamic>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t4.{core::List::add}(dynVar);
+      #t4.{core::List::add}{Invariant}(dynVar);
   } =>#t4;
   core::Set<dynamic>* set11 = block {
     final core::Set<dynamic>* #t5 = col::LinkedHashSet::•<dynamic>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t5.{core::Set::add}(dynVar);
-    #t5.{core::Set::add}(null);
+      #t5.{core::Set::add}{Invariant}(dynVar);
+    #t5.{core::Set::add}{Invariant}(null);
   } =>#t5;
   core::Map<core::String*, dynamic>* map11 = block {
     final core::Map<core::String*, dynamic>* #t6 = <core::String*, dynamic>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t6.{core::Map::[]=}("bar", dynVar);
-    #t6.{core::Map::[]=}("baz", null);
+      #t6.{core::Map::[]=}{Invariant}("bar", dynVar);
+    #t6.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t6;
   core::List<core::List<core::int*>*>* list12 = block {
     final core::List<core::List<core::int*>*>* #t7 = <core::List<core::int*>*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t7.{core::List::add}(<core::int*>[42]);
+      #t7.{core::List::add}{Invariant}(<core::int*>[42]);
   } =>#t7;
   core::Set<core::List<core::int*>*>* set12 = block {
     final core::Set<core::List<core::int*>*>* #t8 = col::LinkedHashSet::•<core::List<core::int*>*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t8.{core::Set::add}(<core::int*>[42]);
-    #t8.{core::Set::add}(null);
+      #t8.{core::Set::add}{Invariant}(<core::int*>[42]);
+    #t8.{core::Set::add}{Invariant}(null);
   } =>#t8;
   core::Map<core::String*, core::List<core::int*>*>* map12 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t9 = <core::String*, core::List<core::int*>*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t9.{core::Map::[]=}("bar", <core::int*>[42]);
-    #t9.{core::Map::[]=}("baz", null);
+      #t9.{core::Map::[]=}{Invariant}("bar", <core::int*>[42]);
+    #t9.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t9;
   core::List<core::int*>* list20 = block {
     final core::List<core::int*>* #t10 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::int* #t11 in <core::int*>[42])
-        #t10.{core::List::add}(#t11);
+        #t10.{core::List::add}{Invariant}(#t11);
   } =>#t10;
   core::Set<core::int*>* set20 = block {
     final core::Set<core::int*>* #t12 = col::LinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::int* #t13 in <core::int*>[42])
-        #t12.{core::Set::add}(#t13);
-    #t12.{core::Set::add}(null);
+        #t12.{core::Set::add}{Invariant}(#t13);
+    #t12.{core::Set::add}{Invariant}(null);
   } =>#t12;
   core::Map<core::String*, core::int*>* map20 = block {
     final core::Map<core::String*, core::int*>* #t14 = <core::String*, core::int*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::MapEntry<core::String*, core::int*>* #t15 in <core::String*, core::int*>{"bar": 42}.{core::Map::entries})
-        #t14.{core::Map::[]=}(#t15.{core::MapEntry::key}, #t15.{core::MapEntry::value});
-    #t14.{core::Map::[]=}("baz", null);
+        #t14.{core::Map::[]=}{Invariant}(#t15.{core::MapEntry::key}, #t15.{core::MapEntry::value});
+    #t14.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t14;
   core::List<dynamic>* list21 = block {
     final core::List<dynamic>* #t16 = <dynamic>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final dynamic #t17 in <dynamic>[dynVar])
-        #t16.{core::List::add}(#t17);
+        #t16.{core::List::add}{Invariant}(#t17);
   } =>#t16;
   core::Set<dynamic>* set21 = block {
     final core::Set<dynamic>* #t18 = col::LinkedHashSet::•<dynamic>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final dynamic #t19 in <dynamic>[dynVar])
-        #t18.{core::Set::add}(#t19);
-    #t18.{core::Set::add}(null);
+        #t18.{core::Set::add}{Invariant}(#t19);
+    #t18.{core::Set::add}{Invariant}(null);
   } =>#t18;
   core::Map<core::String*, dynamic>* map21 = block {
     final core::Map<core::String*, dynamic>* #t20 = <core::String*, dynamic>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::MapEntry<core::String*, dynamic>* #t21 in <core::String*, dynamic>{"bar": dynVar}.{core::Map::entries})
-        #t20.{core::Map::[]=}(#t21.{core::MapEntry::key}, #t21.{core::MapEntry::value});
-    #t20.{core::Map::[]=}("baz", null);
+        #t20.{core::Map::[]=}{Invariant}(#t21.{core::MapEntry::key}, #t21.{core::MapEntry::value});
+    #t20.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t20;
   core::List<core::List<core::int*>*>* list22 = block {
     final core::List<core::List<core::int*>*>* #t22 = <core::List<core::int*>*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::List<core::int*>* #t23 in <core::List<core::int*>*>[<core::int*>[42]])
-        #t22.{core::List::add}(#t23);
+        #t22.{core::List::add}{Invariant}(#t23);
   } =>#t22;
   core::Set<core::List<core::int*>*>* set22 = block {
     final core::Set<core::List<core::int*>*>* #t24 = col::LinkedHashSet::•<core::List<core::int*>*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::List<core::int*>* #t25 in <core::List<core::int*>*>[<core::int*>[42]])
-        #t24.{core::Set::add}(#t25);
-    #t24.{core::Set::add}(null);
+        #t24.{core::Set::add}{Invariant}(#t25);
+    #t24.{core::Set::add}{Invariant}(null);
   } =>#t24;
   core::Map<core::String*, core::List<core::int*>*>* map22 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t26 = <core::String*, core::List<core::int*>*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::MapEntry<core::String*, core::List<core::int*>*>* #t27 in <core::String*, core::List<core::int*>*>{"bar": <core::int*>[42]}.{core::Map::entries})
-        #t26.{core::Map::[]=}(#t27.{core::MapEntry::key}, #t27.{core::MapEntry::value});
-    #t26.{core::Map::[]=}("baz", null);
+        #t26.{core::Map::[]=}{Invariant}(#t27.{core::MapEntry::key}, #t27.{core::MapEntry::value});
+    #t26.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t26;
   core::List<core::int*>* list30 = block {
     final core::List<core::int*>* #t28 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::int* #t29 in <core::int*>[42])
-          #t28.{core::List::add}(#t29);
+          #t28.{core::List::add}{Invariant}(#t29);
   } =>#t28;
   core::Set<core::int*>* set30 = block {
     final core::Set<core::int*>* #t30 = col::LinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::int* #t31 in <core::int*>[42])
-          #t30.{core::Set::add}(#t31);
-    #t30.{core::Set::add}(null);
+          #t30.{core::Set::add}{Invariant}(#t31);
+    #t30.{core::Set::add}{Invariant}(null);
   } =>#t30;
   core::Map<core::String*, core::int*>* map30 = block {
     final core::Map<core::String*, core::int*>* #t32 = <core::String*, core::int*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::MapEntry<core::String*, core::int*>* #t33 in <core::String*, core::int*>{"bar": 42}.{core::Map::entries})
-          #t32.{core::Map::[]=}(#t33.{core::MapEntry::key}, #t33.{core::MapEntry::value});
-    #t32.{core::Map::[]=}("baz", null);
+          #t32.{core::Map::[]=}{Invariant}(#t33.{core::MapEntry::key}, #t33.{core::MapEntry::value});
+    #t32.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t32;
   core::List<dynamic>* list31 = block {
     final core::List<dynamic>* #t34 = <dynamic>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final dynamic #t35 in <dynamic>[dynVar])
-          #t34.{core::List::add}(#t35);
+          #t34.{core::List::add}{Invariant}(#t35);
   } =>#t34;
   core::Set<dynamic>* set31 = block {
     final core::Set<dynamic>* #t36 = col::LinkedHashSet::•<dynamic>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final dynamic #t37 in <dynamic>[dynVar])
-          #t36.{core::Set::add}(#t37);
-    #t36.{core::Set::add}(null);
+          #t36.{core::Set::add}{Invariant}(#t37);
+    #t36.{core::Set::add}{Invariant}(null);
   } =>#t36;
   core::Map<core::String*, dynamic>* map31 = block {
     final core::Map<core::String*, dynamic>* #t38 = <core::String*, dynamic>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::MapEntry<core::String*, dynamic>* #t39 in <core::String*, dynamic>{"bar": dynVar}.{core::Map::entries})
-          #t38.{core::Map::[]=}(#t39.{core::MapEntry::key}, #t39.{core::MapEntry::value});
-    #t38.{core::Map::[]=}("baz", null);
+          #t38.{core::Map::[]=}{Invariant}(#t39.{core::MapEntry::key}, #t39.{core::MapEntry::value});
+    #t38.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t38;
   core::List<core::List<core::int*>*>* list33 = block {
     final core::List<core::List<core::int*>*>* #t40 = <core::List<core::int*>*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::List<core::int*>* #t41 in <core::List<core::int*>*>[<core::int*>[42]])
-          #t40.{core::List::add}(#t41);
+          #t40.{core::List::add}{Invariant}(#t41);
   } =>#t40;
   core::Set<core::List<core::int*>*>* set33 = block {
     final core::Set<core::List<core::int*>*>* #t42 = col::LinkedHashSet::•<core::List<core::int*>*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::List<core::int*>* #t43 in <core::List<core::int*>*>[<core::int*>[42]])
-          #t42.{core::Set::add}(#t43);
-    #t42.{core::Set::add}(null);
+          #t42.{core::Set::add}{Invariant}(#t43);
+    #t42.{core::Set::add}{Invariant}(null);
   } =>#t42;
   core::Map<core::String*, core::List<core::int*>*>* map33 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t44 = <core::String*, core::List<core::int*>*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::MapEntry<core::String*, core::List<core::int*>*>* #t45 in <core::String*, core::List<core::int*>*>{"bar": <core::int*>[42]}.{core::Map::entries})
-          #t44.{core::Map::[]=}(#t45.{core::MapEntry::key}, #t45.{core::MapEntry::value});
-    #t44.{core::Map::[]=}("baz", null);
+          #t44.{core::Map::[]=}{Invariant}(#t45.{core::MapEntry::key}, #t45.{core::MapEntry::value});
+    #t44.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t44;
   core::List<core::List<core::int*>*>* list40 = block {
     final core::List<core::List<core::int*>*>* #t46 = <core::List<core::int*>*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::List<core::int*>* #t47 in <core::List<core::int*>*>[<core::int*>[]])
-        #t46.{core::List::add}(#t47);
+        #t46.{core::List::add}{Invariant}(#t47);
   } =>#t46;
   core::Set<core::List<core::int*>*>* set40 = block {
     final core::Set<core::List<core::int*>*>* #t48 = col::LinkedHashSet::•<core::List<core::int*>*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::List<core::int*>* #t49 in <core::List<core::int*>*>[<core::int*>[]])
-        #t48.{core::Set::add}(#t49);
-    #t48.{core::Set::add}(null);
+        #t48.{core::Set::add}{Invariant}(#t49);
+    #t48.{core::Set::add}{Invariant}(null);
   } =>#t48;
   core::Map<core::String*, core::List<core::int*>*>* map40 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:41:34: Error: Both Iterable and Map spread elements encountered in ambiguous literal.
   Map<String, List<int>> map40 = {if (oracle(\"foo\")) ...{\"bar\", []}, \"baz\": null};
@@ -652,62 +652,62 @@
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::List<core::int*>* #t51 in block {
         final core::Set<core::List<core::int*>*>* #t52 = col::LinkedHashSet::•<core::List<core::int*>*>();
-        #t52.{core::Set::add}(<core::int*>[]);
+        #t52.{core::Set::add}{Invariant}(<core::int*>[]);
       } =>#t52)
-        #t50.{core::List::add}(#t51);
+        #t50.{core::List::add}{Invariant}(#t51);
   } =>#t50;
   core::Set<core::List<core::int*>*>* set41 = block {
     final core::Set<core::List<core::int*>*>* #t53 = col::LinkedHashSet::•<core::List<core::int*>*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::List<core::int*>* #t54 in block {
         final core::Set<core::List<core::int*>*>* #t55 = col::LinkedHashSet::•<core::List<core::int*>*>();
-        #t55.{core::Set::add}(<core::int*>[]);
+        #t55.{core::Set::add}{Invariant}(<core::int*>[]);
       } =>#t55)
-        #t53.{core::Set::add}(#t54);
-    #t53.{core::Set::add}(null);
+        #t53.{core::Set::add}{Invariant}(#t54);
+    #t53.{core::Set::add}{Invariant}(null);
   } =>#t53;
   core::List<core::List<core::int*>*>* list42 = block {
     final core::List<core::List<core::int*>*>* #t56 = <core::List<core::int*>*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::List<core::int*>* #t57 in <core::List<core::int*>*>[<core::int*>[]])
-          #t56.{core::List::add}(#t57);
+          #t56.{core::List::add}{Invariant}(#t57);
   } =>#t56;
   core::Set<core::List<core::int*>*>* set42 = block {
     final core::Set<core::List<core::int*>*>* #t58 = col::LinkedHashSet::•<core::List<core::int*>*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::List<core::int*>* #t59 in <core::List<core::int*>*>[<core::int*>[]])
-          #t58.{core::Set::add}(#t59);
-    #t58.{core::Set::add}(null);
+          #t58.{core::Set::add}{Invariant}(#t59);
+    #t58.{core::Set::add}{Invariant}(null);
   } =>#t58;
   core::Map<core::String*, core::List<core::int*>*>* map42 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t60 = <core::String*, core::List<core::int*>*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::MapEntry<core::String*, core::List<core::int*>*>* #t61 in <core::String*, core::List<core::int*>*>{"bar": <core::int*>[]}.{core::Map::entries})
-          #t60.{core::Map::[]=}(#t61.{core::MapEntry::key}, #t61.{core::MapEntry::value});
-    #t60.{core::Map::[]=}("baz", null);
+          #t60.{core::Map::[]=}{Invariant}(#t61.{core::MapEntry::key}, #t61.{core::MapEntry::value});
+    #t60.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t60;
   core::List<core::int*>* list50 = block {
     final core::List<core::int*>* #t62 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::int* #t63 in <core::int*>[])
-        #t62.{core::List::add}(#t63);
+        #t62.{core::List::add}{Invariant}(#t63);
   } =>#t62;
   core::Set<core::int*>* set50 = block {
     final core::Set<core::int*>* #t64 = col::LinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::int* #t65 in <core::int*>[])
-        #t64.{core::Set::add}(#t65);
-    #t64.{core::Set::add}(null);
+        #t64.{core::Set::add}{Invariant}(#t65);
+    #t64.{core::Set::add}{Invariant}(null);
   } =>#t64;
   core::Map<core::String*, core::int*>* map50 = block {
     final core::Map<core::String*, core::int*>* #t66 = <core::String*, core::int*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::MapEntry<core::String*, core::int*>* #t67 in <core::String*, core::int*>{}.{core::Map::entries})
-        #t66.{core::Map::[]=}(#t67.{core::MapEntry::key}, #t67.{core::MapEntry::value});
-    #t66.{core::Map::[]=}("baz", null);
+        #t66.{core::Map::[]=}{Invariant}(#t67.{core::MapEntry::key}, #t67.{core::MapEntry::value});
+    #t66.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t66;
   core::List<core::int*>* list51 = block {
     final core::List<core::int*>* #t68 = <core::int*>[];
@@ -715,7 +715,7 @@
       for (final core::int* #t69 in block {
         final core::Set<core::int*>* #t70 = col::LinkedHashSet::•<core::int*>();
       } =>#t70)
-        #t68.{core::List::add}(#t69);
+        #t68.{core::List::add}{Invariant}(#t69);
   } =>#t68;
   core::Set<core::int*>* set51 = block {
     final core::Set<core::int*>* #t71 = col::LinkedHashSet::•<core::int*>();
@@ -723,231 +723,231 @@
       for (final core::int* #t72 in block {
         final core::Set<core::int*>* #t73 = col::LinkedHashSet::•<core::int*>();
       } =>#t73)
-        #t71.{core::Set::add}(#t72);
-    #t71.{core::Set::add}(null);
+        #t71.{core::Set::add}{Invariant}(#t72);
+    #t71.{core::Set::add}{Invariant}(null);
   } =>#t71;
   core::List<core::int*>* list52 = block {
     final core::List<core::int*>* #t74 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::int* #t75 in <core::int*>[])
-          #t74.{core::List::add}(#t75);
+          #t74.{core::List::add}{Invariant}(#t75);
   } =>#t74;
   core::Set<core::int*>* set52 = block {
     final core::Set<core::int*>* #t76 = col::LinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::int* #t77 in <core::int*>[])
-          #t76.{core::Set::add}(#t77);
-    #t76.{core::Set::add}(null);
+          #t76.{core::Set::add}{Invariant}(#t77);
+    #t76.{core::Set::add}{Invariant}(null);
   } =>#t76;
   core::Map<core::String*, core::int*>* map52 = block {
     final core::Map<core::String*, core::int*>* #t78 = <core::String*, core::int*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::MapEntry<core::String*, core::int*>* #t79 in <core::String*, core::int*>{}.{core::Map::entries})
-          #t78.{core::Map::[]=}(#t79.{core::MapEntry::key}, #t79.{core::MapEntry::value});
-    #t78.{core::Map::[]=}("baz", null);
+          #t78.{core::Map::[]=}{Invariant}(#t79.{core::MapEntry::key}, #t79.{core::MapEntry::value});
+    #t78.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t78;
   core::List<core::List<core::int*>*>* list60 = block {
     final core::List<core::List<core::int*>*>* #t80 = <core::List<core::int*>*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::List<core::int*>* #t81 in <core::List<core::int*>*>[<core::int*>[]])
-        #t80.{core::List::add}(#t81);
+        #t80.{core::List::add}{Invariant}(#t81);
   } =>#t80;
   core::Set<core::List<core::int*>*>* set60 = block {
     final core::Set<core::List<core::int*>*>* #t82 = col::LinkedHashSet::•<core::List<core::int*>*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::List<core::int*>* #t83 in <core::List<core::int*>*>[<core::int*>[]])
-        #t82.{core::Set::add}(#t83);
-    #t82.{core::Set::add}(null);
+        #t82.{core::Set::add}{Invariant}(#t83);
+    #t82.{core::Set::add}{Invariant}(null);
   } =>#t82;
   core::Map<core::String*, core::List<core::int*>*>* map60 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t84 = <core::String*, core::List<core::int*>*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::MapEntry<core::String*, core::List<core::int*>*>* #t85 in <core::String*, core::List<core::int*>*>{"bar": <core::int*>[]}.{core::Map::entries})
-        #t84.{core::Map::[]=}(#t85.{core::MapEntry::key}, #t85.{core::MapEntry::value});
-    #t84.{core::Map::[]=}("baz", null);
+        #t84.{core::Map::[]=}{Invariant}(#t85.{core::MapEntry::key}, #t85.{core::MapEntry::value});
+    #t84.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t84;
   core::List<core::List<core::int*>*>* list61 = block {
     final core::List<core::List<core::int*>*>* #t86 = <core::List<core::int*>*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::List<core::int*>* #t87 in <core::List<core::int*>*>[<core::int*>[]])
-          #t86.{core::List::add}(#t87);
+          #t86.{core::List::add}{Invariant}(#t87);
   } =>#t86;
   core::Set<core::List<core::int*>*>* set61 = block {
     final core::Set<core::List<core::int*>*>* #t88 = col::LinkedHashSet::•<core::List<core::int*>*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::List<core::int*>* #t89 in <core::List<core::int*>*>[<core::int*>[]])
-          #t88.{core::Set::add}(#t89);
-    #t88.{core::Set::add}(null);
+          #t88.{core::Set::add}{Invariant}(#t89);
+    #t88.{core::Set::add}{Invariant}(null);
   } =>#t88;
   core::Map<core::String*, core::List<core::int*>*>* map61 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t90 = <core::String*, core::List<core::int*>*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::MapEntry<core::String*, core::List<core::int*>*>* #t91 in <core::String*, core::List<core::int*>*>{"bar": <core::int*>[]}.{core::Map::entries})
-          #t90.{core::Map::[]=}(#t91.{core::MapEntry::key}, #t91.{core::MapEntry::value});
-    #t90.{core::Map::[]=}("baz", null);
+          #t90.{core::Map::[]=}{Invariant}(#t91.{core::MapEntry::key}, #t91.{core::MapEntry::value});
+    #t90.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t90;
   core::List<core::List<core::int*>*>* list70 = block {
     final core::List<core::List<core::int*>*>* #t92 = <core::List<core::int*>*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t92.{core::List::add}(<core::int*>[]);
+      #t92.{core::List::add}{Invariant}(<core::int*>[]);
   } =>#t92;
   core::Set<core::List<core::int*>*>* set70 = block {
     final core::Set<core::List<core::int*>*>* #t93 = col::LinkedHashSet::•<core::List<core::int*>*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t93.{core::Set::add}(<core::int*>[]);
-    #t93.{core::Set::add}(null);
+      #t93.{core::Set::add}{Invariant}(<core::int*>[]);
+    #t93.{core::Set::add}{Invariant}(null);
   } =>#t93;
   core::List<core::List<core::int*>*>* list71 = block {
     final core::List<core::List<core::int*>*>* #t94 = <core::List<core::int*>*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t94.{core::List::add}(<core::int*>[]);
+        #t94.{core::List::add}{Invariant}(<core::int*>[]);
   } =>#t94;
   core::Set<core::List<core::int*>*>* set71 = block {
     final core::Set<core::List<core::int*>*>* #t95 = col::LinkedHashSet::•<core::List<core::int*>*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t95.{core::Set::add}(<core::int*>[]);
-    #t95.{core::Set::add}(null);
+        #t95.{core::Set::add}{Invariant}(<core::int*>[]);
+    #t95.{core::Set::add}{Invariant}(null);
   } =>#t95;
   core::List<core::num*>* list80 = block {
     final core::List<core::num*>* #t96 = <core::num*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t96.{core::List::add}(42);
+      #t96.{core::List::add}{Invariant}(42);
     else
-      #t96.{core::List::add}(3.14);
+      #t96.{core::List::add}{Invariant}(3.14);
   } =>#t96;
   core::Set<core::num*>* set80 = block {
     final core::Set<core::num*>* #t97 = col::LinkedHashSet::•<core::num*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t97.{core::Set::add}(42);
+      #t97.{core::Set::add}{Invariant}(42);
     else
-      #t97.{core::Set::add}(3.14);
-    #t97.{core::Set::add}(null);
+      #t97.{core::Set::add}{Invariant}(3.14);
+    #t97.{core::Set::add}{Invariant}(null);
   } =>#t97;
   core::Map<core::String*, core::num*>* map80 = block {
     final core::Map<core::String*, core::num*>* #t98 = <core::String*, core::num*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t98.{core::Map::[]=}("bar", 42);
+      #t98.{core::Map::[]=}{Invariant}("bar", 42);
     else
-      #t98.{core::Map::[]=}("bar", 3.14);
-    #t98.{core::Map::[]=}("baz", null);
+      #t98.{core::Map::[]=}{Invariant}("bar", 3.14);
+    #t98.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t98;
   core::List<core::num*>* list81 = block {
     final core::List<core::num*>* #t99 = <core::num*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::num* #t100 in listInt)
-        #t99.{core::List::add}(#t100);
+        #t99.{core::List::add}{Invariant}(#t100);
     else
       for (final core::num* #t101 in listDouble)
-        #t99.{core::List::add}(#t101);
+        #t99.{core::List::add}{Invariant}(#t101);
   } =>#t99;
   core::Set<core::num*>* set81 = block {
     final core::Set<core::num*>* #t102 = col::LinkedHashSet::•<core::num*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::num* #t103 in listInt)
-        #t102.{core::Set::add}(#t103);
+        #t102.{core::Set::add}{Invariant}(#t103);
     else
       for (final core::num* #t104 in listDouble)
-        #t102.{core::Set::add}(#t104);
-    #t102.{core::Set::add}(null);
+        #t102.{core::Set::add}{Invariant}(#t104);
+    #t102.{core::Set::add}{Invariant}(null);
   } =>#t102;
   core::Map<core::String*, core::num*>* map81 = block {
     final core::Map<core::String*, core::num*>* #t105 = <core::String*, core::num*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::MapEntry<core::String*, core::num*>* #t106 in mapToInt.{core::Map::entries})
-        #t105.{core::Map::[]=}(#t106.{core::MapEntry::key}, #t106.{core::MapEntry::value});
+        #t105.{core::Map::[]=}{Invariant}(#t106.{core::MapEntry::key}, #t106.{core::MapEntry::value});
     else
       for (final core::MapEntry<core::String*, core::num*>* #t107 in mapToDouble.{core::Map::entries})
-        #t105.{core::Map::[]=}(#t107.{core::MapEntry::key}, #t107.{core::MapEntry::value});
-    #t105.{core::Map::[]=}("baz", null);
+        #t105.{core::Map::[]=}{Invariant}(#t107.{core::MapEntry::key}, #t107.{core::MapEntry::value});
+    #t105.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t105;
   core::List<dynamic>* list82 = block {
     final core::List<dynamic>* #t108 = <dynamic>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final dynamic #t109 in listInt)
-        #t108.{core::List::add}(#t109);
+        #t108.{core::List::add}{Invariant}(#t109);
     else
       for (final dynamic #t110 in dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*)
-        #t108.{core::List::add}(#t110);
+        #t108.{core::List::add}{Invariant}(#t110);
   } =>#t108;
   core::Set<dynamic>* set82 = block {
     final core::Set<dynamic>* #t111 = col::LinkedHashSet::•<dynamic>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final dynamic #t112 in listInt)
-        #t111.{core::Set::add}(#t112);
+        #t111.{core::Set::add}{Invariant}(#t112);
     else
       for (final dynamic #t113 in dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*)
-        #t111.{core::Set::add}(#t113);
-    #t111.{core::Set::add}(null);
+        #t111.{core::Set::add}{Invariant}(#t113);
+    #t111.{core::Set::add}{Invariant}(null);
   } =>#t111;
   core::Set<dynamic>* map82 = block {
     final core::Set<dynamic>* #t114 = col::LinkedHashSet::•<dynamic>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t114.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:73:38: Error: Unexpected type 'Map<String, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t114.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:73:38: Error: Unexpected type 'Map<String, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   var map82 = {if (oracle(\"foo\")) ...mapToInt else ...dynVar, null};
                                      ^");
     else
       for (final dynamic #t115 in dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*)
-        #t114.{core::Set::add}(#t115);
-    #t114.{core::Set::add}(null);
+        #t114.{core::Set::add}{Invariant}(#t115);
+    #t114.{core::Set::add}{Invariant}(null);
   } =>#t114;
   core::List<core::num*>* list83 = block {
     final core::List<core::num*>* #t116 = <core::num*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t116.{core::List::add}(42);
+      #t116.{core::List::add}{Invariant}(42);
     else
       for (final core::num* #t117 in listDouble)
-        #t116.{core::List::add}(#t117);
+        #t116.{core::List::add}{Invariant}(#t117);
   } =>#t116;
   core::Set<core::num*>* set83 = block {
     final core::Set<core::num*>* #t118 = col::LinkedHashSet::•<core::num*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::num* #t119 in listInt)
-        #t118.{core::Set::add}(#t119);
+        #t118.{core::Set::add}{Invariant}(#t119);
     else
-      #t118.{core::Set::add}(3.14);
-    #t118.{core::Set::add}(null);
+      #t118.{core::Set::add}{Invariant}(3.14);
+    #t118.{core::Set::add}{Invariant}(null);
   } =>#t118;
   core::Map<core::String*, core::num*>* map83 = block {
     final core::Map<core::String*, core::num*>* #t120 = <core::String*, core::num*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final core::MapEntry<core::String*, core::num*>* #t121 in mapToInt.{core::Map::entries})
-        #t120.{core::Map::[]=}(#t121.{core::MapEntry::key}, #t121.{core::MapEntry::value});
+        #t120.{core::Map::[]=}{Invariant}(#t121.{core::MapEntry::key}, #t121.{core::MapEntry::value});
     else
-      #t120.{core::Map::[]=}("bar", 3.14);
-    #t120.{core::Map::[]=}("baz", null);
+      #t120.{core::Map::[]=}{Invariant}("bar", 3.14);
+    #t120.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t120;
   core::List<core::int*>* list90 = block {
     final core::List<core::int*>* #t122 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t122.{core::List::add}(dynVar as{TypeError,ForDynamic} core::int*);
+      #t122.{core::List::add}{Invariant}(dynVar as{TypeError,ForDynamic} core::int*);
   } =>#t122;
   core::Set<core::int*>* set90 = block {
     final core::Set<core::int*>* #t123 = col::LinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t123.{core::Set::add}(dynVar as{TypeError,ForDynamic} core::int*);
-    #t123.{core::Set::add}(null);
+      #t123.{core::Set::add}{Invariant}(dynVar as{TypeError,ForDynamic} core::int*);
+    #t123.{core::Set::add}{Invariant}(null);
   } =>#t123;
   core::Map<core::String*, core::int*>* map90 = block {
     final core::Map<core::String*, core::int*>* #t124 = <core::String*, core::int*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t124.{core::Map::[]=}("bar", dynVar as{TypeError,ForDynamic} core::int*);
-    #t124.{core::Map::[]=}("baz", null);
+      #t124.{core::Map::[]=}{Invariant}("bar", dynVar as{TypeError,ForDynamic} core::int*);
+    #t124.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t124;
   core::List<core::int*>* list91 = block {
     final core::List<core::int*>* #t125 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final dynamic #t126 in dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*) {
         final core::int* #t127 = #t126 as{TypeError} core::int*;
-        #t125.{core::List::add}(#t127);
+        #t125.{core::List::add}{Invariant}(#t127);
       }
   } =>#t125;
   core::Set<core::int*>* set91 = block {
@@ -955,9 +955,9 @@
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       for (final dynamic #t129 in dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*) {
         final core::int* #t130 = #t129 as{TypeError} core::int*;
-        #t128.{core::Set::add}(#t130);
+        #t128.{core::Set::add}{Invariant}(#t130);
       }
-    #t128.{core::Set::add}(null);
+    #t128.{core::Set::add}{Invariant}(null);
   } =>#t128;
   core::Map<core::String*, core::int*>* map91 = block {
     final core::Map<core::String*, core::int*>* #t131 = <core::String*, core::int*>{};
@@ -965,49 +965,49 @@
       for (final core::MapEntry<dynamic, dynamic>* #t132 in (dynVar as{TypeError,ForDynamic} core::Map<dynamic, dynamic>*).{core::Map::entries}) {
         final core::String* #t133 = #t132.{core::MapEntry::key} as{TypeError} core::String*;
         final core::int* #t134 = #t132.{core::MapEntry::value} as{TypeError} core::int*;
-        #t131.{core::Map::[]=}(#t133, #t134);
+        #t131.{core::Map::[]=}{Invariant}(#t133, #t134);
       }
-    #t131.{core::Map::[]=}("baz", null);
+    #t131.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t131;
   core::List<core::int*>* list100 = block {
     final core::List<core::int*>* #t135 = <core::int*>[];
     if(dynVar as{TypeError,ForDynamic} core::bool*)
-      #t135.{core::List::add}(42);
+      #t135.{core::List::add}{Invariant}(42);
   } =>#t135;
   core::Set<core::int*>* set100 = block {
     final core::Set<core::int*>* #t136 = col::LinkedHashSet::•<core::int*>();
     if(dynVar as{TypeError,ForDynamic} core::bool*)
-      #t136.{core::Set::add}(42);
+      #t136.{core::Set::add}{Invariant}(42);
   } =>#t136;
   core::Map<core::int*, core::int*>* map100 = block {
     final core::Map<core::int*, core::int*>* #t137 = <core::int*, core::int*>{};
     if(dynVar as{TypeError,ForDynamic} core::bool*)
-      #t137.{core::Map::[]=}(42, 42);
+      #t137.{core::Map::[]=}{Invariant}(42, 42);
   } =>#t137;
 }
 static method testIfElementErrors(core::Map<core::int*, core::int*>* map) → dynamic {
   block {
     final core::List<core::int*>* #t138 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t138.{core::List::add}(let final<BottomType> #t139 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:89:28: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+      #t138.{core::List::add}{Invariant}(let final<BottomType> #t139 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:89:28: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int>[if (oracle(\"foo\")) \"bar\"];
                            ^" in "bar" as{TypeError} core::int*);
   } =>#t138;
   block {
     final core::Set<core::int*>* #t140 = col::LinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t140.{core::Set::add}(let final<BottomType> #t141 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:90:28: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+      #t140.{core::Set::add}{Invariant}(let final<BottomType> #t141 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:90:28: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int>{if (oracle(\"foo\")) \"bar\", null};
                            ^" in "bar" as{TypeError} core::int*);
-    #t140.{core::Set::add}(null);
+    #t140.{core::Set::add}{Invariant}(null);
   } =>#t140;
   block {
     final core::Map<core::String*, core::int*>* #t142 = <core::String*, core::int*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t142.{core::Map::[]=}("bar", let final<BottomType> #t143 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:91:43: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+      #t142.{core::Map::[]=}{Invariant}("bar", let final<BottomType> #t143 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:91:43: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <String, int>{if (oracle(\"foo\")) \"bar\": \"bar\", \"baz\": null};
                                           ^" in "bar" as{TypeError} core::int*);
-    #t142.{core::Map::[]=}("baz", null);
+    #t142.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t142;
   block {
     final core::List<core::int*>* #t144 = <core::int*>[];
@@ -1015,7 +1015,7 @@
       for (final core::int* #t145 in <core::int*>[let final<BottomType> #t146 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:92:32: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int>[if (oracle(\"foo\")) ...[\"bar\"]];
                                ^" in "bar" as{TypeError} core::int*])
-        #t144.{core::List::add}(#t145);
+        #t144.{core::List::add}{Invariant}(#t145);
   } =>#t144;
   block {
     final core::Set<core::int*>* #t147 = col::LinkedHashSet::•<core::int*>();
@@ -1023,8 +1023,8 @@
       for (final core::int* #t148 in <core::int*>[let final<BottomType> #t149 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:93:32: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int>{if (oracle(\"foo\")) ...[\"bar\"], null};
                                ^" in "bar" as{TypeError} core::int*])
-        #t147.{core::Set::add}(#t148);
-    #t147.{core::Set::add}(null);
+        #t147.{core::Set::add}{Invariant}(#t148);
+    #t147.{core::Set::add}{Invariant}(null);
   } =>#t147;
   block {
     final core::Map<core::String*, core::int*>* #t150 = <core::String*, core::int*>{};
@@ -1032,13 +1032,13 @@
       for (final core::MapEntry<core::String*, core::int*>* #t151 in <core::String*, core::int*>{"bar": let final<BottomType> #t152 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:94:47: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <String, int>{if (oracle(\"foo\")) ...{\"bar\": \"bar\"}, \"baz\": null};
                                               ^" in "bar" as{TypeError} core::int*}.{core::Map::entries})
-        #t150.{core::Map::[]=}(#t151.{core::MapEntry::key}, #t151.{core::MapEntry::value});
-    #t150.{core::Map::[]=}("baz", null);
+        #t150.{core::Map::[]=}{Invariant}(#t151.{core::MapEntry::key}, #t151.{core::MapEntry::value});
+    #t150.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t150;
   block {
     final core::List<core::int*>* #t153 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t153.{core::List::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:95:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t153.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:95:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>[if (oracle(\"foo\")) ...map];
                               ^");
@@ -1046,11 +1046,11 @@
   block {
     final core::Set<core::int*>* #t154 = col::LinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t154.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:96:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t154.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:96:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>{if (oracle(\"foo\")) ...map, null};
                               ^");
-    #t154.{core::Set::add}(null);
+    #t154.{core::Set::add}{Invariant}(null);
   } =>#t154;
   <core::String*, core::int*>{invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:97:39: Error: Unexpected type 'List<String>' of a map spread entry.  Expected 'dynamic' or a Map.
  - 'List' is from 'dart:core'.
@@ -1062,58 +1062,58 @@
   block {
     final core::List<core::String*>* #t155 = <core::String*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t155.{core::List::add}(let final<BottomType> #t156 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:98:31: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+      #t155.{core::List::add}{Invariant}(let final<BottomType> #t156 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:98:31: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   <String>[if (oracle(\"foo\")) 42 else 3.14];
                               ^" in 42 as{TypeError} core::String*);
     else
-      #t155.{core::List::add}(let final<BottomType> #t157 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:98:39: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
+      #t155.{core::List::add}{Invariant}(let final<BottomType> #t157 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:98:39: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
   <String>[if (oracle(\"foo\")) 42 else 3.14];
                                       ^" in 3.14 as{TypeError} core::String*);
   } =>#t155;
   block {
     final core::Set<core::String*>* #t158 = col::LinkedHashSet::•<core::String*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t158.{core::Set::add}(let final<BottomType> #t159 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:99:31: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+      #t158.{core::Set::add}{Invariant}(let final<BottomType> #t159 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:99:31: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   <String>{if (oracle(\"foo\")) 42 else 3.14, null};
                               ^" in 42 as{TypeError} core::String*);
     else
-      #t158.{core::Set::add}(let final<BottomType> #t160 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:99:39: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
+      #t158.{core::Set::add}{Invariant}(let final<BottomType> #t160 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:99:39: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
   <String>{if (oracle(\"foo\")) 42 else 3.14, null};
                                       ^" in 3.14 as{TypeError} core::String*);
-    #t158.{core::Set::add}(null);
+    #t158.{core::Set::add}{Invariant}(null);
   } =>#t158;
   block {
     final core::Map<core::String*, core::String*>* #t161 = <core::String*, core::String*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t161.{core::Map::[]=}("bar", let final<BottomType> #t162 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:100:46: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+      #t161.{core::Map::[]=}{Invariant}("bar", let final<BottomType> #t162 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:100:46: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   <String, String>{if (oracle(\"foo\")) \"bar\": 42 else \"baz\": 3.14, \"baz\": null};
                                              ^" in 42 as{TypeError} core::String*);
     else
-      #t161.{core::Map::[]=}("baz", let final<BottomType> #t163 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:100:61: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
+      #t161.{core::Map::[]=}{Invariant}("baz", let final<BottomType> #t163 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:100:61: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
   <String, String>{if (oracle(\"foo\")) \"bar\": 42 else \"baz\": 3.14, \"baz\": null};
                                                             ^" in 3.14 as{TypeError} core::String*);
-    #t161.{core::Map::[]=}("baz", null);
+    #t161.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t161;
   block {
     final core::List<core::int*>* #t164 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t164.{core::List::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:101:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t164.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:101:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>[if (oracle(\"foo\")) ...map else 42];
                               ^");
     else
-      #t164.{core::List::add}(42);
+      #t164.{core::List::add}{Invariant}(42);
   } =>#t164;
   block {
     final core::Set<core::int*>* #t165 = col::LinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t165.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:102:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t165.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:102:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>{if (oracle(\"foo\")) ...map else 42, null};
                               ^");
     else
-      #t165.{core::Set::add}(42);
-    #t165.{core::Set::add}(null);
+      #t165.{core::Set::add}{Invariant}(42);
+    #t165.{core::Set::add}{Invariant}(null);
   } =>#t165;
   <core::String*, core::int*>{invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:103:39: Error: Unexpected type 'List<int>' of a map spread entry.  Expected 'dynamic' or a Map.
  - 'List' is from 'dart:core'.
@@ -1125,9 +1125,9 @@
   block {
     final core::List<core::int*>* #t166 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t166.{core::List::add}(42);
+      #t166.{core::List::add}{Invariant}(42);
     else
-      #t166.{core::List::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:104:39: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t166.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:104:39: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>[if (oracle(\"foo\")) 42 else ...map];
                                       ^");
@@ -1135,13 +1135,13 @@
   block {
     final core::Set<core::int*>* #t167 = col::LinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t167.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:105:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t167.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:105:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>{if (oracle(\"foo\")) ...map else 42, null};
                               ^");
     else
-      #t167.{core::Set::add}(42);
-    #t167.{core::Set::add}(null);
+      #t167.{core::Set::add}{Invariant}(42);
+    #t167.{core::Set::add}{Invariant}(null);
   } =>#t167;
   <core::String*, core::int*>{invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:106:54: Error: Unexpected type 'List<int>' of a map spread entry.  Expected 'dynamic' or a Map.
  - 'List' is from 'dart:core'.
@@ -1173,63 +1173,63 @@
     if(let final<BottomType> #t169 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:114:27: Error: A value of type 'int' can't be assigned to a variable of type 'bool'.
   List<int> list20 = [if (42) 42];
                           ^" in 42 as{TypeError} core::bool*)
-      #t168.{core::List::add}(42);
+      #t168.{core::List::add}{Invariant}(42);
   } =>#t168;
   core::Set<core::int*>* set20 = block {
     final core::Set<core::int*>* #t170 = col::LinkedHashSet::•<core::int*>();
     if(let final<BottomType> #t171 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:115:25: Error: A value of type 'int' can't be assigned to a variable of type 'bool'.
   Set<int> set20 = {if (42) 42};
                         ^" in 42 as{TypeError} core::bool*)
-      #t170.{core::Set::add}(42);
+      #t170.{core::Set::add}{Invariant}(42);
   } =>#t170;
   core::Map<core::int*, core::int*>* map30 = block {
     final core::Map<core::int*, core::int*>* #t172 = <core::int*, core::int*>{};
     if(let final<BottomType> #t173 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:116:30: Error: A value of type 'int' can't be assigned to a variable of type 'bool'.
   Map<int, int> map30 = {if (42) 42: 42};
                              ^" in 42 as{TypeError} core::bool*)
-      #t172.{core::Map::[]=}(42, 42);
+      #t172.{core::Map::[]=}{Invariant}(42, 42);
   } =>#t172;
   core::List<core::String*>* list40 = block {
     final core::List<core::String*>* #t174 = <core::String*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t174.{core::List::add}(let final<BottomType> #t175 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:117:53: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
+      #t174.{core::List::add}{Invariant}(let final<BottomType> #t175 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:117:53: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
   List<String> list40 = <String>[if (oracle(\"foo\")) true else 42];
                                                     ^" in true as{TypeError} core::String*);
     else
-      #t174.{core::List::add}(let final<BottomType> #t176 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:117:63: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+      #t174.{core::List::add}{Invariant}(let final<BottomType> #t176 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:117:63: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   List<String> list40 = <String>[if (oracle(\"foo\")) true else 42];
                                                               ^" in 42 as{TypeError} core::String*);
   } =>#t174;
   core::Set<core::String*>* set40 = block {
     final core::Set<core::String*>* #t177 = col::LinkedHashSet::•<core::String*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t177.{core::Set::add}(let final<BottomType> #t178 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:118:51: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
+      #t177.{core::Set::add}{Invariant}(let final<BottomType> #t178 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:118:51: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
   Set<String> set40 = <String>{if (oracle(\"foo\")) true else 42};
                                                   ^" in true as{TypeError} core::String*);
     else
-      #t177.{core::Set::add}(let final<BottomType> #t179 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:118:61: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+      #t177.{core::Set::add}{Invariant}(let final<BottomType> #t179 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:118:61: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   Set<String> set40 = <String>{if (oracle(\"foo\")) true else 42};
                                                             ^" in 42 as{TypeError} core::String*);
   } =>#t177;
   core::Map<core::String*, core::int*>* map40 = block {
     final core::Map<core::String*, core::int*>* #t180 = <core::String*, core::int*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t180.{core::Map::[]=}(let final<BottomType> #t181 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:119:61: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
+      #t180.{core::Map::[]=}{Invariant}(let final<BottomType> #t181 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:119:61: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
   Map<String, int> map40 = <String, int>{if (oracle(\"foo\")) true: 42 else 42: 42};
                                                             ^" in true as{TypeError} core::String*, 42);
     else
-      #t180.{core::Map::[]=}(let final<BottomType> #t182 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:119:75: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+      #t180.{core::Map::[]=}{Invariant}(let final<BottomType> #t182 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:119:75: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   Map<String, int> map40 = <String, int>{if (oracle(\"foo\")) true: 42 else 42: 42};
                                                                           ^" in 42 as{TypeError} core::String*, 42);
   } =>#t180;
   core::Map<core::int*, core::String*>* map41 = block {
     final core::Map<core::int*, core::String*>* #t183 = <core::int*, core::String*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t183.{core::Map::[]=}(42, let final<BottomType> #t184 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:120:65: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
+      #t183.{core::Map::[]=}{Invariant}(42, let final<BottomType> #t184 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:120:65: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
   Map<int, String> map41 = <int, String>{if (oracle(\"foo\")) 42: true else 42: 42};
                                                                 ^" in true as{TypeError} core::String*);
     else
-      #t183.{core::Map::[]=}(42, let final<BottomType> #t185 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:120:79: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+      #t183.{core::Map::[]=}{Invariant}(42, let final<BottomType> #t185 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:120:79: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   Map<int, String> map41 = <int, String>{if (oracle(\"foo\")) 42: true else 42: 42};
                                                                               ^" in 42 as{TypeError} core::String*);
   } =>#t183;
@@ -1238,264 +1238,264 @@
   core::List<core::int*>* list10 = block {
     final core::List<core::int*>* #t186 = <core::int*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t186.{core::List::add}(42);
+      #t186.{core::List::add}{Invariant}(42);
   } =>#t186;
   core::Set<core::int*>* set10 = block {
     final core::Set<core::int*>* #t187 = col::LinkedHashSet::•<core::int*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t187.{core::Set::add}(42);
-    #t187.{core::Set::add}(null);
+      #t187.{core::Set::add}{Invariant}(42);
+    #t187.{core::Set::add}{Invariant}(null);
   } =>#t187;
   core::Map<core::String*, core::int*>* map10 = block {
     final core::Map<core::String*, core::int*>* #t188 = <core::String*, core::int*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t188.{core::Map::[]=}("bar", 42);
-    #t188.{core::Map::[]=}("baz", null);
+      #t188.{core::Map::[]=}{Invariant}("bar", 42);
+    #t188.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t188;
   core::List<dynamic>* list11 = block {
     final core::List<dynamic>* #t189 = <dynamic>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t189.{core::List::add}(dynVar);
+      #t189.{core::List::add}{Invariant}(dynVar);
   } =>#t189;
   core::Set<dynamic>* set11 = block {
     final core::Set<dynamic>* #t190 = col::LinkedHashSet::•<dynamic>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t190.{core::Set::add}(dynVar);
-    #t190.{core::Set::add}(null);
+      #t190.{core::Set::add}{Invariant}(dynVar);
+    #t190.{core::Set::add}{Invariant}(null);
   } =>#t190;
   core::Map<core::String*, dynamic>* map11 = block {
     final core::Map<core::String*, dynamic>* #t191 = <core::String*, dynamic>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t191.{core::Map::[]=}("bar", dynVar);
-    #t191.{core::Map::[]=}("baz", null);
+      #t191.{core::Map::[]=}{Invariant}("bar", dynVar);
+    #t191.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t191;
   core::List<core::List<core::int*>*>* list12 = block {
     final core::List<core::List<core::int*>*>* #t192 = <core::List<core::int*>*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t192.{core::List::add}(<core::int*>[42]);
+      #t192.{core::List::add}{Invariant}(<core::int*>[42]);
   } =>#t192;
   core::Set<core::List<core::int*>*>* set12 = block {
     final core::Set<core::List<core::int*>*>* #t193 = col::LinkedHashSet::•<core::List<core::int*>*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t193.{core::Set::add}(<core::int*>[42]);
-    #t193.{core::Set::add}(null);
+      #t193.{core::Set::add}{Invariant}(<core::int*>[42]);
+    #t193.{core::Set::add}{Invariant}(null);
   } =>#t193;
   core::Map<core::String*, core::List<core::int*>*>* map12 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t194 = <core::String*, core::List<core::int*>*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t194.{core::Map::[]=}("bar", <core::int*>[42]);
-    #t194.{core::Map::[]=}("baz", null);
+      #t194.{core::Map::[]=}{Invariant}("bar", <core::int*>[42]);
+    #t194.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t194;
   core::List<core::int*>* list20 = block {
     final core::List<core::int*>* #t195 = <core::int*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::int* #t196 in <core::int*>[42])
-        #t195.{core::List::add}(#t196);
+        #t195.{core::List::add}{Invariant}(#t196);
   } =>#t195;
   core::Set<core::int*>* set20 = block {
     final core::Set<core::int*>* #t197 = col::LinkedHashSet::•<core::int*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::int* #t198 in <core::int*>[42])
-        #t197.{core::Set::add}(#t198);
-    #t197.{core::Set::add}(null);
+        #t197.{core::Set::add}{Invariant}(#t198);
+    #t197.{core::Set::add}{Invariant}(null);
   } =>#t197;
   core::Map<core::String*, core::int*>* map20 = block {
     final core::Map<core::String*, core::int*>* #t199 = <core::String*, core::int*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::MapEntry<core::String*, core::int*>* #t200 in <core::String*, core::int*>{"bar": 42}.{core::Map::entries})
-        #t199.{core::Map::[]=}(#t200.{core::MapEntry::key}, #t200.{core::MapEntry::value});
-    #t199.{core::Map::[]=}("baz", null);
+        #t199.{core::Map::[]=}{Invariant}(#t200.{core::MapEntry::key}, #t200.{core::MapEntry::value});
+    #t199.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t199;
   core::List<dynamic>* list21 = block {
     final core::List<dynamic>* #t201 = <dynamic>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final dynamic #t202 in <dynamic>[dynVar])
-        #t201.{core::List::add}(#t202);
+        #t201.{core::List::add}{Invariant}(#t202);
   } =>#t201;
   core::Set<dynamic>* set21 = block {
     final core::Set<dynamic>* #t203 = col::LinkedHashSet::•<dynamic>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final dynamic #t204 in <dynamic>[dynVar])
-        #t203.{core::Set::add}(#t204);
-    #t203.{core::Set::add}(null);
+        #t203.{core::Set::add}{Invariant}(#t204);
+    #t203.{core::Set::add}{Invariant}(null);
   } =>#t203;
   core::Map<core::String*, dynamic>* map21 = block {
     final core::Map<core::String*, dynamic>* #t205 = <core::String*, dynamic>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::MapEntry<core::String*, dynamic>* #t206 in <core::String*, dynamic>{"bar": dynVar}.{core::Map::entries})
-        #t205.{core::Map::[]=}(#t206.{core::MapEntry::key}, #t206.{core::MapEntry::value});
-    #t205.{core::Map::[]=}("baz", null);
+        #t205.{core::Map::[]=}{Invariant}(#t206.{core::MapEntry::key}, #t206.{core::MapEntry::value});
+    #t205.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t205;
   core::List<core::List<core::int*>*>* list22 = block {
     final core::List<core::List<core::int*>*>* #t207 = <core::List<core::int*>*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::List<core::int*>* #t208 in <core::List<core::int*>*>[<core::int*>[42]])
-        #t207.{core::List::add}(#t208);
+        #t207.{core::List::add}{Invariant}(#t208);
   } =>#t207;
   core::Set<core::List<core::int*>*>* set22 = block {
     final core::Set<core::List<core::int*>*>* #t209 = col::LinkedHashSet::•<core::List<core::int*>*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::List<core::int*>* #t210 in <core::List<core::int*>*>[<core::int*>[42]])
-        #t209.{core::Set::add}(#t210);
-    #t209.{core::Set::add}(null);
+        #t209.{core::Set::add}{Invariant}(#t210);
+    #t209.{core::Set::add}{Invariant}(null);
   } =>#t209;
   core::Map<core::String*, core::List<core::int*>*>* map22 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t211 = <core::String*, core::List<core::int*>*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::MapEntry<core::String*, core::List<core::int*>*>* #t212 in <core::String*, core::List<core::int*>*>{"bar": <core::int*>[42]}.{core::Map::entries})
-        #t211.{core::Map::[]=}(#t212.{core::MapEntry::key}, #t212.{core::MapEntry::value});
-    #t211.{core::Map::[]=}("baz", null);
+        #t211.{core::Map::[]=}{Invariant}(#t212.{core::MapEntry::key}, #t212.{core::MapEntry::value});
+    #t211.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t211;
   core::List<core::int*>* list30 = block {
     final core::List<core::int*>* #t213 = <core::int*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::int* #t214 in <core::int*>[42])
-          #t213.{core::List::add}(#t214);
+          #t213.{core::List::add}{Invariant}(#t214);
   } =>#t213;
   core::Set<core::int*>* set30 = block {
     final core::Set<core::int*>* #t215 = col::LinkedHashSet::•<core::int*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::int* #t216 in <core::int*>[42])
-          #t215.{core::Set::add}(#t216);
-    #t215.{core::Set::add}(null);
+          #t215.{core::Set::add}{Invariant}(#t216);
+    #t215.{core::Set::add}{Invariant}(null);
   } =>#t215;
   core::Map<core::String*, core::int*>* map30 = block {
     final core::Map<core::String*, core::int*>* #t217 = <core::String*, core::int*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::MapEntry<core::String*, core::int*>* #t218 in <core::String*, core::int*>{"bar": 42}.{core::Map::entries})
-          #t217.{core::Map::[]=}(#t218.{core::MapEntry::key}, #t218.{core::MapEntry::value});
-    #t217.{core::Map::[]=}("baz", null);
+          #t217.{core::Map::[]=}{Invariant}(#t218.{core::MapEntry::key}, #t218.{core::MapEntry::value});
+    #t217.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t217;
   core::List<dynamic>* list31 = block {
     final core::List<dynamic>* #t219 = <dynamic>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final dynamic #t220 in <dynamic>[dynVar])
-          #t219.{core::List::add}(#t220);
+          #t219.{core::List::add}{Invariant}(#t220);
   } =>#t219;
   core::Set<dynamic>* set31 = block {
     final core::Set<dynamic>* #t221 = col::LinkedHashSet::•<dynamic>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final dynamic #t222 in <dynamic>[dynVar])
-          #t221.{core::Set::add}(#t222);
-    #t221.{core::Set::add}(null);
+          #t221.{core::Set::add}{Invariant}(#t222);
+    #t221.{core::Set::add}{Invariant}(null);
   } =>#t221;
   core::Map<core::String*, dynamic>* map31 = block {
     final core::Map<core::String*, dynamic>* #t223 = <core::String*, dynamic>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::MapEntry<core::String*, dynamic>* #t224 in <core::String*, dynamic>{"bar": dynVar}.{core::Map::entries})
-          #t223.{core::Map::[]=}(#t224.{core::MapEntry::key}, #t224.{core::MapEntry::value});
-    #t223.{core::Map::[]=}("baz", null);
+          #t223.{core::Map::[]=}{Invariant}(#t224.{core::MapEntry::key}, #t224.{core::MapEntry::value});
+    #t223.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t223;
   core::List<core::List<core::int*>*>* list33 = block {
     final core::List<core::List<core::int*>*>* #t225 = <core::List<core::int*>*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::List<core::int*>* #t226 in <core::List<core::int*>*>[<core::int*>[42]])
-          #t225.{core::List::add}(#t226);
+          #t225.{core::List::add}{Invariant}(#t226);
   } =>#t225;
   core::Set<core::List<core::int*>*>* set33 = block {
     final core::Set<core::List<core::int*>*>* #t227 = col::LinkedHashSet::•<core::List<core::int*>*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::List<core::int*>* #t228 in <core::List<core::int*>*>[<core::int*>[42]])
-          #t227.{core::Set::add}(#t228);
-    #t227.{core::Set::add}(null);
+          #t227.{core::Set::add}{Invariant}(#t228);
+    #t227.{core::Set::add}{Invariant}(null);
   } =>#t227;
   core::Map<core::String*, core::List<core::int*>*>* map33 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t229 = <core::String*, core::List<core::int*>*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::MapEntry<core::String*, core::List<core::int*>*>* #t230 in <core::String*, core::List<core::int*>*>{"bar": <core::int*>[42]}.{core::Map::entries})
-          #t229.{core::Map::[]=}(#t230.{core::MapEntry::key}, #t230.{core::MapEntry::value});
-    #t229.{core::Map::[]=}("baz", null);
+          #t229.{core::Map::[]=}{Invariant}(#t230.{core::MapEntry::key}, #t230.{core::MapEntry::value});
+    #t229.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t229;
   core::List<core::List<core::int*>*>* list40 = block {
     final core::List<core::List<core::int*>*>* #t231 = <core::List<core::int*>*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::List<core::int*>* #t232 in <core::List<core::int*>*>[<core::int*>[]])
-        #t231.{core::List::add}(#t232);
+        #t231.{core::List::add}{Invariant}(#t232);
   } =>#t231;
   core::Set<core::List<core::int*>*>* set40 = block {
     final core::Set<core::List<core::int*>*>* #t233 = col::LinkedHashSet::•<core::List<core::int*>*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::List<core::int*>* #t234 in <core::List<core::int*>*>[<core::int*>[]])
-        #t233.{core::Set::add}(#t234);
-    #t233.{core::Set::add}(null);
+        #t233.{core::Set::add}{Invariant}(#t234);
+    #t233.{core::Set::add}{Invariant}(null);
   } =>#t233;
   core::Map<core::String*, core::List<core::int*>*>* map40 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t235 = <core::String*, core::List<core::int*>*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::MapEntry<core::String*, core::List<core::int*>*>* #t236 in <core::String*, core::List<core::int*>*>{"bar": <core::int*>[]}.{core::Map::entries})
-        #t235.{core::Map::[]=}(#t236.{core::MapEntry::key}, #t236.{core::MapEntry::value});
-    #t235.{core::Map::[]=}("baz", null);
+        #t235.{core::Map::[]=}{Invariant}(#t236.{core::MapEntry::key}, #t236.{core::MapEntry::value});
+    #t235.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t235;
   core::List<core::List<core::int*>*>* list41 = block {
     final core::List<core::List<core::int*>*>* #t237 = <core::List<core::int*>*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::List<core::int*>* #t238 in block {
         final core::Set<core::List<core::int*>*>* #t239 = col::LinkedHashSet::•<core::List<core::int*>*>();
-        #t239.{core::Set::add}(<core::int*>[]);
+        #t239.{core::Set::add}{Invariant}(<core::int*>[]);
       } =>#t239)
-        #t237.{core::List::add}(#t238);
+        #t237.{core::List::add}{Invariant}(#t238);
   } =>#t237;
   core::Set<core::List<core::int*>*>* set41 = block {
     final core::Set<core::List<core::int*>*>* #t240 = col::LinkedHashSet::•<core::List<core::int*>*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::List<core::int*>* #t241 in block {
         final core::Set<core::List<core::int*>*>* #t242 = col::LinkedHashSet::•<core::List<core::int*>*>();
-        #t242.{core::Set::add}(<core::int*>[]);
+        #t242.{core::Set::add}{Invariant}(<core::int*>[]);
       } =>#t242)
-        #t240.{core::Set::add}(#t241);
-    #t240.{core::Set::add}(null);
+        #t240.{core::Set::add}{Invariant}(#t241);
+    #t240.{core::Set::add}{Invariant}(null);
   } =>#t240;
   core::List<core::List<core::int*>*>* list42 = block {
     final core::List<core::List<core::int*>*>* #t243 = <core::List<core::int*>*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::List<core::int*>* #t244 in <core::List<core::int*>*>[<core::int*>[]])
-          #t243.{core::List::add}(#t244);
+          #t243.{core::List::add}{Invariant}(#t244);
   } =>#t243;
   core::Set<core::List<core::int*>*>* set42 = block {
     final core::Set<core::List<core::int*>*>* #t245 = col::LinkedHashSet::•<core::List<core::int*>*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::List<core::int*>* #t246 in <core::List<core::int*>*>[<core::int*>[]])
-          #t245.{core::Set::add}(#t246);
-    #t245.{core::Set::add}(null);
+          #t245.{core::Set::add}{Invariant}(#t246);
+    #t245.{core::Set::add}{Invariant}(null);
   } =>#t245;
   core::Map<core::String*, core::List<core::int*>*>* map42 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t247 = <core::String*, core::List<core::int*>*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::MapEntry<core::String*, core::List<core::int*>*>* #t248 in <core::String*, core::List<core::int*>*>{"bar": <core::int*>[]}.{core::Map::entries})
-          #t247.{core::Map::[]=}(#t248.{core::MapEntry::key}, #t248.{core::MapEntry::value});
-    #t247.{core::Map::[]=}("baz", null);
+          #t247.{core::Map::[]=}{Invariant}(#t248.{core::MapEntry::key}, #t248.{core::MapEntry::value});
+    #t247.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t247;
   core::List<core::int*>* list50 = block {
     final core::List<core::int*>* #t249 = <core::int*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::int* #t250 in <core::int*>[])
-        #t249.{core::List::add}(#t250);
+        #t249.{core::List::add}{Invariant}(#t250);
   } =>#t249;
   core::Set<core::int*>* set50 = block {
     final core::Set<core::int*>* #t251 = col::LinkedHashSet::•<core::int*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::int* #t252 in <core::int*>[])
-        #t251.{core::Set::add}(#t252);
-    #t251.{core::Set::add}(null);
+        #t251.{core::Set::add}{Invariant}(#t252);
+    #t251.{core::Set::add}{Invariant}(null);
   } =>#t251;
   core::Map<core::String*, core::int*>* map50 = block {
     final core::Map<core::String*, core::int*>* #t253 = <core::String*, core::int*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::MapEntry<core::String*, core::int*>* #t254 in <core::String*, core::int*>{}.{core::Map::entries})
-        #t253.{core::Map::[]=}(#t254.{core::MapEntry::key}, #t254.{core::MapEntry::value});
-    #t253.{core::Map::[]=}("baz", null);
+        #t253.{core::Map::[]=}{Invariant}(#t254.{core::MapEntry::key}, #t254.{core::MapEntry::value});
+    #t253.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t253;
   core::List<core::int*>* list51 = block {
     final core::List<core::int*>* #t255 = <core::int*>[];
@@ -1503,7 +1503,7 @@
       for (final core::int* #t256 in block {
         final core::Set<core::int*>* #t257 = col::LinkedHashSet::•<core::int*>();
       } =>#t257)
-        #t255.{core::List::add}(#t256);
+        #t255.{core::List::add}{Invariant}(#t256);
   } =>#t255;
   core::Set<core::int*>* set51 = block {
     final core::Set<core::int*>* #t258 = col::LinkedHashSet::•<core::int*>();
@@ -1511,246 +1511,246 @@
       for (final core::int* #t259 in block {
         final core::Set<core::int*>* #t260 = col::LinkedHashSet::•<core::int*>();
       } =>#t260)
-        #t258.{core::Set::add}(#t259);
-    #t258.{core::Set::add}(null);
+        #t258.{core::Set::add}{Invariant}(#t259);
+    #t258.{core::Set::add}{Invariant}(null);
   } =>#t258;
   core::List<core::int*>* list52 = block {
     final core::List<core::int*>* #t261 = <core::int*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::int* #t262 in <core::int*>[])
-          #t261.{core::List::add}(#t262);
+          #t261.{core::List::add}{Invariant}(#t262);
   } =>#t261;
   core::Set<core::int*>* set52 = block {
     final core::Set<core::int*>* #t263 = col::LinkedHashSet::•<core::int*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::int* #t264 in <core::int*>[])
-          #t263.{core::Set::add}(#t264);
-    #t263.{core::Set::add}(null);
+          #t263.{core::Set::add}{Invariant}(#t264);
+    #t263.{core::Set::add}{Invariant}(null);
   } =>#t263;
   core::List<core::List<core::int*>*>* list60 = block {
     final core::List<core::List<core::int*>*>* #t265 = <core::List<core::int*>*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::List<core::int*>* #t266 in <core::List<core::int*>*>[<core::int*>[]])
-        #t265.{core::List::add}(#t266);
+        #t265.{core::List::add}{Invariant}(#t266);
   } =>#t265;
   core::Set<core::List<core::int*>*>* set60 = block {
     final core::Set<core::List<core::int*>*>* #t267 = col::LinkedHashSet::•<core::List<core::int*>*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::List<core::int*>* #t268 in <core::List<core::int*>*>[<core::int*>[]])
-        #t267.{core::Set::add}(#t268);
-    #t267.{core::Set::add}(null);
+        #t267.{core::Set::add}{Invariant}(#t268);
+    #t267.{core::Set::add}{Invariant}(null);
   } =>#t267;
   core::Map<core::String*, core::List<core::int*>*>* map60 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t269 = <core::String*, core::List<core::int*>*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final core::MapEntry<core::String*, core::List<core::int*>*>* #t270 in <core::String*, core::List<core::int*>*>{"bar": <core::int*>[]}.{core::Map::entries})
-        #t269.{core::Map::[]=}(#t270.{core::MapEntry::key}, #t270.{core::MapEntry::value});
-    #t269.{core::Map::[]=}("baz", null);
+        #t269.{core::Map::[]=}{Invariant}(#t270.{core::MapEntry::key}, #t270.{core::MapEntry::value});
+    #t269.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t269;
   core::List<core::List<core::int*>*>* list61 = block {
     final core::List<core::List<core::int*>*>* #t271 = <core::List<core::int*>*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::List<core::int*>* #t272 in <core::List<core::int*>*>[<core::int*>[]])
-          #t271.{core::List::add}(#t272);
+          #t271.{core::List::add}{Invariant}(#t272);
   } =>#t271;
   core::Set<core::List<core::int*>*>* set61 = block {
     final core::Set<core::List<core::int*>*>* #t273 = col::LinkedHashSet::•<core::List<core::int*>*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::List<core::int*>* #t274 in <core::List<core::int*>*>[<core::int*>[]])
-          #t273.{core::Set::add}(#t274);
-    #t273.{core::Set::add}(null);
+          #t273.{core::Set::add}{Invariant}(#t274);
+    #t273.{core::Set::add}{Invariant}(null);
   } =>#t273;
   core::Map<core::String*, core::List<core::int*>*>* map61 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t275 = <core::String*, core::List<core::int*>*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::MapEntry<core::String*, core::List<core::int*>*>* #t276 in <core::String*, core::List<core::int*>*>{"bar": <core::int*>[]}.{core::Map::entries})
-          #t275.{core::Map::[]=}(#t276.{core::MapEntry::key}, #t276.{core::MapEntry::value});
-    #t275.{core::Map::[]=}("baz", null);
+          #t275.{core::Map::[]=}{Invariant}(#t276.{core::MapEntry::key}, #t276.{core::MapEntry::value});
+    #t275.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t275;
   core::List<core::List<core::int*>*>* list70 = block {
     final core::List<core::List<core::int*>*>* #t277 = <core::List<core::int*>*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t277.{core::List::add}(<core::int*>[]);
+      #t277.{core::List::add}{Invariant}(<core::int*>[]);
   } =>#t277;
   core::Set<core::List<core::int*>*>* set70 = block {
     final core::Set<core::List<core::int*>*>* #t278 = col::LinkedHashSet::•<core::List<core::int*>*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t278.{core::Set::add}(<core::int*>[]);
-    #t278.{core::Set::add}(null);
+      #t278.{core::Set::add}{Invariant}(<core::int*>[]);
+    #t278.{core::Set::add}{Invariant}(null);
   } =>#t278;
   core::Map<core::String*, core::List<core::int*>*>* map70 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t279 = <core::String*, core::List<core::int*>*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t279.{core::Map::[]=}("bar", <core::int*>[]);
-    #t279.{core::Map::[]=}("baz", null);
+      #t279.{core::Map::[]=}{Invariant}("bar", <core::int*>[]);
+    #t279.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t279;
   core::List<core::List<core::int*>*>* list71 = block {
     final core::List<core::List<core::int*>*>* #t280 = <core::List<core::int*>*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t280.{core::List::add}(<core::int*>[]);
+        #t280.{core::List::add}{Invariant}(<core::int*>[]);
   } =>#t280;
   core::Set<core::List<core::int*>*>* set71 = block {
     final core::Set<core::List<core::int*>*>* #t281 = col::LinkedHashSet::•<core::List<core::int*>*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t281.{core::Set::add}(<core::int*>[]);
-    #t281.{core::Set::add}(null);
+        #t281.{core::Set::add}{Invariant}(<core::int*>[]);
+    #t281.{core::Set::add}{Invariant}(null);
   } =>#t281;
   core::Map<core::String*, core::List<core::int*>*>* map71 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t282 = <core::String*, core::List<core::int*>*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t282.{core::Map::[]=}("bar", <core::int*>[]);
-    #t282.{core::Map::[]=}("baz", null);
+        #t282.{core::Map::[]=}{Invariant}("bar", <core::int*>[]);
+    #t282.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t282;
   core::List<core::num*>* list80 = block {
     final core::List<core::num*>* #t283 = <core::num*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t283.{core::List::add}(42);
+        #t283.{core::List::add}{Invariant}(42);
       else
-        #t283.{core::List::add}(3.14);
+        #t283.{core::List::add}{Invariant}(3.14);
   } =>#t283;
   core::Set<core::num*>* set80 = block {
     final core::Set<core::num*>* #t284 = col::LinkedHashSet::•<core::num*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t284.{core::Set::add}(42);
+        #t284.{core::Set::add}{Invariant}(42);
       else
-        #t284.{core::Set::add}(3.14);
-    #t284.{core::Set::add}(null);
+        #t284.{core::Set::add}{Invariant}(3.14);
+    #t284.{core::Set::add}{Invariant}(null);
   } =>#t284;
   core::Map<core::String*, core::num*>* map80 = block {
     final core::Map<core::String*, core::num*>* #t285 = <core::String*, core::num*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t285.{core::Map::[]=}("bar", 42);
+        #t285.{core::Map::[]=}{Invariant}("bar", 42);
       else
-        #t285.{core::Map::[]=}("bar", 3.14);
-    #t285.{core::Map::[]=}("baz", null);
+        #t285.{core::Map::[]=}{Invariant}("bar", 3.14);
+    #t285.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t285;
   core::List<core::num*>* list81 = block {
     final core::List<core::num*>* #t286 = <core::num*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::num* #t287 in listInt)
-          #t286.{core::List::add}(#t287);
+          #t286.{core::List::add}{Invariant}(#t287);
       else
         for (final core::num* #t288 in listDouble)
-          #t286.{core::List::add}(#t288);
+          #t286.{core::List::add}{Invariant}(#t288);
   } =>#t286;
   core::Set<core::num*>* set81 = block {
     final core::Set<core::num*>* #t289 = col::LinkedHashSet::•<core::num*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::num* #t290 in listInt)
-          #t289.{core::Set::add}(#t290);
+          #t289.{core::Set::add}{Invariant}(#t290);
       else
         for (final core::num* #t291 in listDouble)
-          #t289.{core::Set::add}(#t291);
-    #t289.{core::Set::add}(null);
+          #t289.{core::Set::add}{Invariant}(#t291);
+    #t289.{core::Set::add}{Invariant}(null);
   } =>#t289;
   core::Map<core::String*, core::num*>* map81 = block {
     final core::Map<core::String*, core::num*>* #t292 = <core::String*, core::num*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::MapEntry<core::String*, core::num*>* #t293 in mapStringInt.{core::Map::entries})
-          #t292.{core::Map::[]=}(#t293.{core::MapEntry::key}, #t293.{core::MapEntry::value});
+          #t292.{core::Map::[]=}{Invariant}(#t293.{core::MapEntry::key}, #t293.{core::MapEntry::value});
       else
         for (final core::MapEntry<core::String*, core::num*>* #t294 in mapStringDouble.{core::Map::entries})
-          #t292.{core::Map::[]=}(#t294.{core::MapEntry::key}, #t294.{core::MapEntry::value});
-    #t292.{core::Map::[]=}("baz", null);
+          #t292.{core::Map::[]=}{Invariant}(#t294.{core::MapEntry::key}, #t294.{core::MapEntry::value});
+    #t292.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t292;
   core::List<dynamic>* list82 = block {
     final core::List<dynamic>* #t295 = <dynamic>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final dynamic #t296 in listInt)
-          #t295.{core::List::add}(#t296);
+          #t295.{core::List::add}{Invariant}(#t296);
       else
         for (final dynamic #t297 in dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*)
-          #t295.{core::List::add}(#t297);
+          #t295.{core::List::add}{Invariant}(#t297);
   } =>#t295;
   core::Set<dynamic>* set82 = block {
     final core::Set<dynamic>* #t298 = col::LinkedHashSet::•<dynamic>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final dynamic #t299 in listInt)
-          #t298.{core::Set::add}(#t299);
+          #t298.{core::Set::add}{Invariant}(#t299);
       else
         for (final dynamic #t300 in dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*)
-          #t298.{core::Set::add}(#t300);
-    #t298.{core::Set::add}(null);
+          #t298.{core::Set::add}{Invariant}(#t300);
+    #t298.{core::Set::add}{Invariant}(null);
   } =>#t298;
   core::Map<dynamic, dynamic>* map82 = block {
     final core::Map<dynamic, dynamic>* #t301 = <dynamic, dynamic>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::MapEntry<dynamic, dynamic>* #t302 in mapStringInt.{core::Map::entries})
-          #t301.{core::Map::[]=}(#t302.{core::MapEntry::key}, #t302.{core::MapEntry::value});
+          #t301.{core::Map::[]=}{Invariant}(#t302.{core::MapEntry::key}, #t302.{core::MapEntry::value});
       else
         for (final core::MapEntry<dynamic, dynamic>* #t303 in (dynVar as{TypeError,ForDynamic} core::Map<dynamic, dynamic>*).{core::Map::entries})
-          #t301.{core::Map::[]=}(#t303.{core::MapEntry::key}, #t303.{core::MapEntry::value});
-    #t301.{core::Map::[]=}("baz", null);
+          #t301.{core::Map::[]=}{Invariant}(#t303.{core::MapEntry::key}, #t303.{core::MapEntry::value});
+    #t301.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t301;
   core::List<core::num*>* list83 = block {
     final core::List<core::num*>* #t304 = <core::num*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t304.{core::List::add}(42);
+        #t304.{core::List::add}{Invariant}(42);
       else
         for (final core::num* #t305 in listDouble)
-          #t304.{core::List::add}(#t305);
+          #t304.{core::List::add}{Invariant}(#t305);
   } =>#t304;
   core::Set<core::num*>* set83 = block {
     final core::Set<core::num*>* #t306 = col::LinkedHashSet::•<core::num*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::num* #t307 in listInt)
-          #t306.{core::Set::add}(#t307);
+          #t306.{core::Set::add}{Invariant}(#t307);
       else
-        #t306.{core::Set::add}(3.14);
-    #t306.{core::Set::add}(null);
+        #t306.{core::Set::add}{Invariant}(3.14);
+    #t306.{core::Set::add}{Invariant}(null);
   } =>#t306;
   core::Map<core::String*, core::num*>* map83 = block {
     final core::Map<core::String*, core::num*>* #t308 = <core::String*, core::num*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
         for (final core::MapEntry<core::String*, core::num*>* #t309 in mapStringInt.{core::Map::entries})
-          #t308.{core::Map::[]=}(#t309.{core::MapEntry::key}, #t309.{core::MapEntry::value});
+          #t308.{core::Map::[]=}{Invariant}(#t309.{core::MapEntry::key}, #t309.{core::MapEntry::value});
       else
-        #t308.{core::Map::[]=}("bar", 3.14);
-    #t308.{core::Map::[]=}("baz", null);
+        #t308.{core::Map::[]=}{Invariant}("bar", 3.14);
+    #t308.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t308;
   core::List<core::int*>* list90 = block {
     final core::List<core::int*>* #t310 = <core::int*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t310.{core::List::add}(dynVar as{TypeError,ForDynamic} core::int*);
+      #t310.{core::List::add}{Invariant}(dynVar as{TypeError,ForDynamic} core::int*);
   } =>#t310;
   core::Set<core::int*>* set90 = block {
     final core::Set<core::int*>* #t311 = col::LinkedHashSet::•<core::int*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t311.{core::Set::add}(dynVar as{TypeError,ForDynamic} core::int*);
-    #t311.{core::Set::add}(null);
+      #t311.{core::Set::add}{Invariant}(dynVar as{TypeError,ForDynamic} core::int*);
+    #t311.{core::Set::add}{Invariant}(null);
   } =>#t311;
   core::Map<core::String*, core::int*>* map90 = block {
     final core::Map<core::String*, core::int*>* #t312 = <core::String*, core::int*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t312.{core::Map::[]=}("bar", dynVar as{TypeError,ForDynamic} core::int*);
-    #t312.{core::Map::[]=}("baz", null);
+      #t312.{core::Map::[]=}{Invariant}("bar", dynVar as{TypeError,ForDynamic} core::int*);
+    #t312.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t312;
   core::List<core::int*>* list91 = block {
     final core::List<core::int*>* #t313 = <core::int*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final dynamic #t314 in dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*) {
         final core::int* #t315 = #t314 as{TypeError} core::int*;
-        #t313.{core::List::add}(#t315);
+        #t313.{core::List::add}{Invariant}(#t315);
       }
   } =>#t313;
   core::Set<core::int*>* set91 = block {
@@ -1758,9 +1758,9 @@
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       for (final dynamic #t317 in dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*) {
         final core::int* #t318 = #t317 as{TypeError} core::int*;
-        #t316.{core::Set::add}(#t318);
+        #t316.{core::Set::add}{Invariant}(#t318);
       }
-    #t316.{core::Set::add}(null);
+    #t316.{core::Set::add}{Invariant}(null);
   } =>#t316;
   core::Map<core::String*, core::int*>* map91 = block {
     final core::Map<core::String*, core::int*>* #t319 = <core::String*, core::int*>{};
@@ -1768,100 +1768,100 @@
       for (final core::MapEntry<dynamic, dynamic>* #t320 in (dynVar as{TypeError,ForDynamic} core::Map<dynamic, dynamic>*).{core::Map::entries}) {
         final core::String* #t321 = #t320.{core::MapEntry::key} as{TypeError} core::String*;
         final core::int* #t322 = #t320.{core::MapEntry::value} as{TypeError} core::int*;
-        #t319.{core::Map::[]=}(#t321, #t322);
+        #t319.{core::Map::[]=}{Invariant}(#t321, #t322);
       }
-    #t319.{core::Map::[]=}("baz", null);
+    #t319.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t319;
   core::List<core::int*>* list100 = block {
     final core::List<core::int*>* #t323 = <core::int*>[];
     for (final core::int* #t324 = index = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; index = index.{core::num::+}(1))
-      #t323.{core::List::add}(42);
+      #t323.{core::List::add}{Invariant}(42);
   } =>#t323;
   core::Set<core::int*>* set100 = block {
     final core::Set<core::int*>* #t325 = col::LinkedHashSet::•<core::int*>();
     for (final core::int* #t326 = index = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; index = index.{core::num::+}(1))
-      #t325.{core::Set::add}(42);
+      #t325.{core::Set::add}{Invariant}(42);
   } =>#t325;
   core::Map<core::String*, core::int*>* map100 = block {
     final core::Map<core::String*, core::int*>* #t327 = <core::String*, core::int*>{};
     for (final core::int* #t328 = index = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; index = index.{core::num::+}(1))
-      #t327.{core::Map::[]=}("bar", 42);
+      #t327.{core::Map::[]=}{Invariant}("bar", 42);
   } =>#t327;
   core::List<core::int*>* list110 = block {
     final core::List<core::int*>* #t329 = <core::int*>[];
     for (core::int* i in <core::int*>[1, 2, 3])
-      #t329.{core::List::add}(i);
+      #t329.{core::List::add}{Invariant}(i);
   } =>#t329;
   core::Set<core::int*>* set110 = block {
     final core::Set<core::int*>* #t330 = col::LinkedHashSet::•<core::int*>();
     for (core::int* i in <core::int*>[1, 2, 3])
-      #t330.{core::Set::add}(i);
-    #t330.{core::Set::add}(null);
+      #t330.{core::Set::add}{Invariant}(i);
+    #t330.{core::Set::add}{Invariant}(null);
   } =>#t330;
   core::Map<core::String*, core::int*>* map110 = block {
     final core::Map<core::String*, core::int*>* #t331 = <core::String*, core::int*>{};
     for (core::int* i in <core::int*>[1, 2, 3])
-      #t331.{core::Map::[]=}("bar", i);
-    #t331.{core::Map::[]=}("baz", null);
+      #t331.{core::Map::[]=}{Invariant}("bar", i);
+    #t331.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t331;
   core::List<core::int*>* list120 = block {
     final core::List<core::int*>* #t332 = <core::int*>[];
     for (dynamic i in dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*)
-      #t332.{core::List::add}(i as{TypeError,ForDynamic} core::int*);
+      #t332.{core::List::add}{Invariant}(i as{TypeError,ForDynamic} core::int*);
   } =>#t332;
   core::Set<core::int*>* set120 = block {
     final core::Set<core::int*>* #t333 = col::LinkedHashSet::•<core::int*>();
     for (dynamic i in dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*)
-      #t333.{core::Set::add}(i as{TypeError,ForDynamic} core::int*);
-    #t333.{core::Set::add}(null);
+      #t333.{core::Set::add}{Invariant}(i as{TypeError,ForDynamic} core::int*);
+    #t333.{core::Set::add}{Invariant}(null);
   } =>#t333;
   core::Map<core::String*, core::int*>* map120 = block {
     final core::Map<core::String*, core::int*>* #t334 = <core::String*, core::int*>{};
     for (dynamic i in dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*)
-      #t334.{core::Map::[]=}("bar", i as{TypeError,ForDynamic} core::int*);
-    #t334.{core::Map::[]=}("baz", null);
+      #t334.{core::Map::[]=}{Invariant}("bar", i as{TypeError,ForDynamic} core::int*);
+    #t334.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t334;
   core::List<core::int*>* list130 = block {
     final core::List<core::int*>* #t335 = <core::int*>[];
     for (core::int* i = 1; i.{core::num::<}(2); i = i.{core::num::+}(1))
-      #t335.{core::List::add}(i);
+      #t335.{core::List::add}{Invariant}(i);
   } =>#t335;
   core::Set<core::int*>* set130 = block {
     final core::Set<core::int*>* #t336 = col::LinkedHashSet::•<core::int*>();
     for (core::int* i = 1; i.{core::num::<}(2); i = i.{core::num::+}(1))
-      #t336.{core::Set::add}(i);
+      #t336.{core::Set::add}{Invariant}(i);
   } =>#t336;
   core::Map<core::int*, core::int*>* map130 = block {
     final core::Map<core::int*, core::int*>* #t337 = <core::int*, core::int*>{};
     for (core::int* i = 1; i.{core::num::<}(2); i = i.{core::num::+}(1))
-      #t337.{core::Map::[]=}(i, i);
+      #t337.{core::Map::[]=}{Invariant}(i, i);
   } =>#t337;
 }
 static method testForElementErrors(core::Map<core::int*, core::int*>* map, core::List<core::int*>* list) → dynamic async {
   block {
     final core::List<core::int*>* #t338 = <core::int*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t338.{core::List::add}(let final<BottomType> #t339 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:212:45: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+      #t338.{core::List::add}{Invariant}(let final<BottomType> #t339 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:212:45: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int>[for (int i = 0; oracle(\"foo\"); i++) \"bar\"];
                                             ^" in "bar" as{TypeError} core::int*);
   } =>#t338;
   block {
     final core::Set<core::int*>* #t340 = col::LinkedHashSet::•<core::int*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t340.{core::Set::add}(let final<BottomType> #t341 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:213:45: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+      #t340.{core::Set::add}{Invariant}(let final<BottomType> #t341 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:213:45: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int>{for (int i = 0; oracle(\"foo\"); i++) \"bar\", null};
                                             ^" in "bar" as{TypeError} core::int*);
-    #t340.{core::Set::add}(null);
+    #t340.{core::Set::add}{Invariant}(null);
   } =>#t340;
   block {
     final core::Map<core::int*, core::int*>* #t342 = <core::int*, core::int*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t342.{core::Map::[]=}(let final<BottomType> #t343 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:214:50: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+      #t342.{core::Map::[]=}{Invariant}(let final<BottomType> #t343 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:214:50: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int, int>{for (int i = 0; oracle(\"foo\"); i++) \"bar\": \"bar\", \"baz\": null};
                                                  ^" in "bar" as{TypeError} core::int*, let final<BottomType> #t344 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:214:57: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int, int>{for (int i = 0; oracle(\"foo\"); i++) \"bar\": \"bar\", \"baz\": null};
                                                         ^" in "bar" as{TypeError} core::int*);
-    #t342.{core::Map::[]=}(let final<BottomType> #t345 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:214:64: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+    #t342.{core::Map::[]=}{Invariant}(let final<BottomType> #t345 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:214:64: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int, int>{for (int i = 0; oracle(\"foo\"); i++) \"bar\": \"bar\", \"baz\": null};
                                                                ^" in "baz" as{TypeError} core::int*, null);
   } =>#t342;
@@ -1871,7 +1871,7 @@
       for (final core::int* #t347 in <core::int*>[let final<BottomType> #t348 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:215:49: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int>[for (int i = 0; oracle(\"foo\"); i++) ...[\"bar\"]];
                                                 ^" in "bar" as{TypeError} core::int*])
-        #t346.{core::List::add}(#t347);
+        #t346.{core::List::add}{Invariant}(#t347);
   } =>#t346;
   block {
     final core::Set<core::int*>* #t349 = col::LinkedHashSet::•<core::int*>();
@@ -1879,8 +1879,8 @@
       for (final core::int* #t350 in <core::int*>[let final<BottomType> #t351 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:216:49: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int>{for (int i = 0; oracle(\"foo\"); i++) ...[\"bar\"], null};
                                                 ^" in "bar" as{TypeError} core::int*])
-        #t349.{core::Set::add}(#t350);
-    #t349.{core::Set::add}(null);
+        #t349.{core::Set::add}{Invariant}(#t350);
+    #t349.{core::Set::add}{Invariant}(null);
   } =>#t349;
   block {
     final core::Map<core::int*, core::int*>* #t352 = <core::int*, core::int*>{};
@@ -1890,15 +1890,15 @@
                                                      ^" in "bar" as{TypeError} core::int*: let final<BottomType> #t355 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:217:61: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int, int>{for (int i = 0; oracle(\"foo\"); i++) ...{\"bar\": \"bar\"}, \"baz\": null};
                                                             ^" in "bar" as{TypeError} core::int*}.{core::Map::entries})
-        #t352.{core::Map::[]=}(#t353.{core::MapEntry::key}, #t353.{core::MapEntry::value});
-    #t352.{core::Map::[]=}(let final<BottomType> #t356 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:217:69: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+        #t352.{core::Map::[]=}{Invariant}(#t353.{core::MapEntry::key}, #t353.{core::MapEntry::value});
+    #t352.{core::Map::[]=}{Invariant}(let final<BottomType> #t356 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:217:69: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int, int>{for (int i = 0; oracle(\"foo\"); i++) ...{\"bar\": \"bar\"}, \"baz\": null};
                                                                     ^" in "baz" as{TypeError} core::int*, null);
   } =>#t352;
   block {
     final core::List<core::int*>* #t357 = <core::int*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t357.{core::List::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:218:48: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t357.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:218:48: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>[for (int i = 0; oracle(\"foo\"); i++) ...map];
                                                ^");
@@ -1906,11 +1906,11 @@
   block {
     final core::Set<core::int*>* #t358 = col::LinkedHashSet::•<core::int*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t358.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:219:48: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t358.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:219:48: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>{for (int i = 0; oracle(\"foo\"); i++) ...map, null};
                                                ^");
-    #t358.{core::Set::add}(null);
+    #t358.{core::Set::add}{Invariant}(null);
   } =>#t358;
   <core::int*, core::int*>{invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:220:53: Error: Unexpected type 'List<int>' of a map spread entry.  Expected 'dynamic' or a Map.
  - 'List' is from 'dart:core'.
@@ -1923,11 +1923,11 @@
     final core::List<core::String*>* #t359 = <core::String*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t359.{core::List::add}(let final<BottomType> #t360 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:221:62: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+        #t359.{core::List::add}{Invariant}(let final<BottomType> #t360 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:221:62: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   <String>[for (int i = 0; oracle(\"foo\"); i++) if (oracle()) 42 else 3.14];
                                                              ^" in 42 as{TypeError} core::String*);
       else
-        #t359.{core::List::add}(let final<BottomType> #t361 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:221:70: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
+        #t359.{core::List::add}{Invariant}(let final<BottomType> #t361 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:221:70: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
   <String>[for (int i = 0; oracle(\"foo\"); i++) if (oracle()) 42 else 3.14];
                                                                      ^" in 3.14 as{TypeError} core::String*);
   } =>#t359;
@@ -1935,50 +1935,50 @@
     final core::Set<core::String*>* #t362 = col::LinkedHashSet::•<core::String*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t362.{core::Set::add}(let final<BottomType> #t363 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:222:62: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+        #t362.{core::Set::add}{Invariant}(let final<BottomType> #t363 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:222:62: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   <String>{for (int i = 0; oracle(\"foo\"); i++) if (oracle()) 42 else 3.14, null};
                                                              ^" in 42 as{TypeError} core::String*);
       else
-        #t362.{core::Set::add}(let final<BottomType> #t364 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:222:70: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
+        #t362.{core::Set::add}{Invariant}(let final<BottomType> #t364 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:222:70: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
   <String>{for (int i = 0; oracle(\"foo\"); i++) if (oracle()) 42 else 3.14, null};
                                                                      ^" in 3.14 as{TypeError} core::String*);
-    #t362.{core::Set::add}(null);
+    #t362.{core::Set::add}{Invariant}(null);
   } =>#t362;
   block {
     final core::Map<core::String*, core::String*>* #t365 = <core::String*, core::String*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t365.{core::Map::[]=}("bar", let final<BottomType> #t366 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:223:77: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+        #t365.{core::Map::[]=}{Invariant}("bar", let final<BottomType> #t366 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:223:77: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   <String, String>{for (int i = 0; oracle(\"foo\"); i++) if (oracle()) \"bar\": 42 else \"bar\": 3.14, \"baz\": null};
                                                                             ^" in 42 as{TypeError} core::String*);
       else
-        #t365.{core::Map::[]=}("bar", let final<BottomType> #t367 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:223:92: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
+        #t365.{core::Map::[]=}{Invariant}("bar", let final<BottomType> #t367 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:223:92: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
   <String, String>{for (int i = 0; oracle(\"foo\"); i++) if (oracle()) \"bar\": 42 else \"bar\": 3.14, \"baz\": null};
                                                                                            ^" in 3.14 as{TypeError} core::String*);
-    #t365.{core::Map::[]=}("baz", null);
+    #t365.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t365;
   block {
     final core::List<core::int*>* #t368 = <core::int*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t368.{core::List::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:224:62: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+        #t368.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:224:62: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>[for (int i = 0; oracle(\"foo\"); i++) if (oracle()) ...map else 42];
                                                              ^");
       else
-        #t368.{core::List::add}(42);
+        #t368.{core::List::add}{Invariant}(42);
   } =>#t368;
   block {
     final core::Set<core::int*>* #t369 = col::LinkedHashSet::•<core::int*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t369.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:225:62: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+        #t369.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:225:62: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>{for (int i = 0; oracle(\"foo\"); i++) if (oracle()) ...map else 42, null};
                                                              ^");
       else
-        #t369.{core::Set::add}(42);
-    #t369.{core::Set::add}(null);
+        #t369.{core::Set::add}{Invariant}(42);
+    #t369.{core::Set::add}{Invariant}(null);
   } =>#t369;
   <core::String*, core::int*>{invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:226:70: Error: Unexpected type 'List<int>' of a map spread entry.  Expected 'dynamic' or a Map.
  - 'List' is from 'dart:core'.
@@ -1991,9 +1991,9 @@
     final core::List<core::int*>* #t370 = <core::int*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t370.{core::List::add}(42);
+        #t370.{core::List::add}{Invariant}(42);
       else
-        #t370.{core::List::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:227:70: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+        #t370.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:227:70: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>[for (int i = 0; oracle(\"foo\"); i++) if (oracle()) 42 else ...map];
                                                                      ^");
@@ -2002,13 +2002,13 @@
     final core::Set<core::int*>* #t371 = col::LinkedHashSet::•<core::int*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t371.{core::Set::add}(42);
+        #t371.{core::Set::add}{Invariant}(42);
       else
-        #t371.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:228:70: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+        #t371.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:228:70: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>{for (int i = 0; oracle(\"foo\"); i++) if (oracle()) 42 else ...map, null};
                                                                      ^");
-    #t371.{core::Set::add}(null);
+    #t371.{core::Set::add}{Invariant}(null);
   } =>#t371;
   <core::String*, core::int*>{invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:229:85: Error: Unexpected type 'List<int>' of a map spread entry.  Expected 'dynamic' or a Map.
  - 'List' is from 'dart:core'.
@@ -2024,7 +2024,7 @@
       invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:232:14: Error: Can't assign to the final variable 'i'.
   <int>[for (i in <int>[1]) i];
              ^";
-      #t372.{core::List::add}(i);
+      #t372.{core::List::add}{Invariant}(i);
     }
   } =>#t372;
   block {
@@ -2033,9 +2033,9 @@
       invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:233:14: Error: Can't assign to the final variable 'i'.
   <int>{for (i in <int>[1]) i, null};
              ^";
-      #t374.{core::Set::add}(i);
+      #t374.{core::Set::add}{Invariant}(i);
     }
-    #t374.{core::Set::add}(null);
+    #t374.{core::Set::add}{Invariant}(null);
   } =>#t374;
   block {
     final core::Map<core::String*, core::int*>* #t376 = <core::String*, core::int*>{};
@@ -2043,9 +2043,9 @@
       invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:234:21: Error: Can't assign to the final variable 'i'.
 \t<String, int>{for (i in <int>[1]) \"bar\": i, \"baz\": null};
 \t                   ^";
-      #t376.{core::Map::[]=}("bar", i);
+      #t376.{core::Map::[]=}{Invariant}("bar", i);
     }
-    #t376.{core::Map::[]=}("baz", null);
+    #t376.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t376;
   core::List<dynamic>* list10 = block {
     final core::List<dynamic>* #t378 = <dynamic>[];
@@ -2053,7 +2053,7 @@
  - 'Iterable' is from 'dart:core'.
   var list10 = [for (var i in \"not iterable\") i];
                               ^" in "not iterable" as{TypeError} core::Iterable<dynamic>*)
-      #t378.{core::List::add}(i);
+      #t378.{core::List::add}{Invariant}(i);
   } =>#t378;
   core::Set<dynamic>* set10 = block {
     final core::Set<dynamic>* #t380 = col::LinkedHashSet::•<dynamic>();
@@ -2061,8 +2061,8 @@
  - 'Iterable' is from 'dart:core'.
   var set10 = {for (var i in \"not iterable\") i, null};
                              ^" in "not iterable" as{TypeError} core::Iterable<dynamic>*)
-      #t380.{core::Set::add}(i);
-    #t380.{core::Set::add}(null);
+      #t380.{core::Set::add}{Invariant}(i);
+    #t380.{core::Set::add}{Invariant}(null);
   } =>#t380;
   core::Map<core::String*, dynamic>* map10 = block {
     final core::Map<core::String*, dynamic>* #t382 = <core::String*, dynamic>{};
@@ -2070,8 +2070,8 @@
  - 'Iterable' is from 'dart:core'.
   var map10 = {for (var i in \"not iterable\") \"bar\": i, \"baz\": null};
                              ^" in "not iterable" as{TypeError} core::Iterable<dynamic>*)
-      #t382.{core::Map::[]=}("bar", i);
-    #t382.{core::Map::[]=}("baz", null);
+      #t382.{core::Map::[]=}{Invariant}("bar", i);
+    #t382.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t382;
   core::List<core::int*>* list20 = block {
     final core::List<core::int*>* #t384 = <core::int*>[];
@@ -2080,7 +2080,7 @@
                                ^" in "not" as{TypeError} core::int*, let final<BottomType> #t386 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:239:39: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   var list20 = [for (int i in [\"not\", \"int\"]) i];
                                       ^" in "int" as{TypeError} core::int*])
-      #t384.{core::List::add}(i);
+      #t384.{core::List::add}{Invariant}(i);
   } =>#t384;
   core::Set<core::int*>* set20 = block {
     final core::Set<core::int*>* #t387 = col::LinkedHashSet::•<core::int*>();
@@ -2089,8 +2089,8 @@
                               ^" in "not" as{TypeError} core::int*, let final<BottomType> #t389 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:240:38: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   var set20 = {for (int i in [\"not\", \"int\"]) i, null};
                                      ^" in "int" as{TypeError} core::int*])
-      #t387.{core::Set::add}(i);
-    #t387.{core::Set::add}(null);
+      #t387.{core::Set::add}{Invariant}(i);
+    #t387.{core::Set::add}{Invariant}(null);
   } =>#t387;
   core::Map<core::String*, core::int*>* map20 = block {
     final core::Map<core::String*, core::int*>* #t390 = <core::String*, core::int*>{};
@@ -2099,8 +2099,8 @@
                               ^" in "not" as{TypeError} core::int*, let final<BottomType> #t392 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:241:38: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   var map20 = {for (int i in [\"not\", \"int\"]) \"bar\": i, \"baz\": null};
                                      ^" in "int" as{TypeError} core::int*])
-      #t390.{core::Map::[]=}("bar", i);
-    #t390.{core::Map::[]=}("baz", null);
+      #t390.{core::Map::[]=}{Invariant}("bar", i);
+    #t390.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t390;
   core::List<dynamic>* list30 = block {
     final core::List<dynamic>* #t393 = <dynamic>[];
@@ -2108,7 +2108,7 @@
  - 'Stream' is from 'dart:async'.
   var list30 = [await for (var i in \"not stream\") i];
                                     ^" in "not stream" as{TypeError} asy::Stream<dynamic>*)
-      #t393.{core::List::add}(i);
+      #t393.{core::List::add}{Invariant}(i);
   } =>#t393;
   core::Set<dynamic>* set30 = block {
     final core::Set<dynamic>* #t395 = col::LinkedHashSet::•<dynamic>();
@@ -2116,8 +2116,8 @@
  - 'Stream' is from 'dart:async'.
   var set30 = {await for (var i in \"not stream\") i, null};
                                    ^" in "not stream" as{TypeError} asy::Stream<dynamic>*)
-      #t395.{core::Set::add}(i);
-    #t395.{core::Set::add}(null);
+      #t395.{core::Set::add}{Invariant}(i);
+    #t395.{core::Set::add}{Invariant}(null);
   } =>#t395;
   core::Map<core::String*, dynamic>* map30 = block {
     final core::Map<core::String*, dynamic>* #t397 = <core::String*, dynamic>{};
@@ -2125,8 +2125,8 @@
  - 'Stream' is from 'dart:async'.
   var map30 = {await for (var i in \"not stream\") \"bar\": i, \"baz\": null};
                                    ^" in "not stream" as{TypeError} asy::Stream<dynamic>*)
-      #t397.{core::Map::[]=}("bar", i);
-    #t397.{core::Map::[]=}("baz", null);
+      #t397.{core::Map::[]=}{Invariant}("bar", i);
+    #t397.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t397;
   core::List<core::int*>* list40 = block {
     final core::List<core::int*>* #t399 = <core::int*>[];
@@ -2135,7 +2135,7 @@
                                                          ^" in "not" as{TypeError} core::int*, let final<BottomType> #t401 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:245:65: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   var list40 = [await for (int i in Stream.fromIterable([\"not\", \"int\"])) i];
                                                                 ^" in "int" as{TypeError} core::int*]))
-      #t399.{core::List::add}(i);
+      #t399.{core::List::add}{Invariant}(i);
   } =>#t399;
   core::Set<core::int*>* set40 = block {
     final core::Set<core::int*>* #t402 = col::LinkedHashSet::•<core::int*>();
@@ -2144,8 +2144,8 @@
                                                         ^" in "not" as{TypeError} core::int*, let final<BottomType> #t404 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:246:64: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   var set40 = {await for (int i in Stream.fromIterable([\"not\", \"int\"])) i, null};
                                                                ^" in "int" as{TypeError} core::int*]))
-      #t402.{core::Set::add}(i);
-    #t402.{core::Set::add}(null);
+      #t402.{core::Set::add}{Invariant}(i);
+    #t402.{core::Set::add}{Invariant}(null);
   } =>#t402;
   core::Map<core::String*, core::int*>* map40 = block {
     final core::Map<core::String*, core::int*>* #t405 = <core::String*, core::int*>{};
@@ -2154,82 +2154,82 @@
                                                         ^" in "not" as{TypeError} core::int*, let final<BottomType> #t407 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:247:64: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   var map40 = {await for (int i in Stream.fromIterable([\"not\", \"int\"])) \"bar\": i, \"baz\": null};
                                                                ^" in "int" as{TypeError} core::int*]))
-      #t405.{core::Map::[]=}("bar", i);
-    #t405.{core::Map::[]=}("baz", null);
+      #t405.{core::Map::[]=}{Invariant}("bar", i);
+    #t405.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t405;
   core::List<core::int*>* list50 = block {
     final core::List<core::int*>* #t408 = <core::int*>[];
     for (; ; )
-      #t408.{core::List::add}(42);
+      #t408.{core::List::add}{Invariant}(42);
   } =>#t408;
   core::Set<core::int*>* set50 = block {
     final core::Set<core::int*>* #t409 = col::LinkedHashSet::•<core::int*>();
     for (; ; )
-      #t409.{core::Set::add}(42);
-    #t409.{core::Set::add}(null);
+      #t409.{core::Set::add}{Invariant}(42);
+    #t409.{core::Set::add}{Invariant}(null);
   } =>#t409;
   core::Map<core::String*, core::int*>* map50 = block {
     final core::Map<core::String*, core::int*>* #t410 = <core::String*, core::int*>{};
     for (; ; )
-      #t410.{core::Map::[]=}("bar", 42);
-    #t410.{core::Map::[]=}("baz", null);
+      #t410.{core::Map::[]=}{Invariant}("bar", 42);
+    #t410.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t410;
   core::List<core::int*>* list60 = block {
     final core::List<core::int*>* #t411 = <core::int*>[];
     for (; let final<BottomType> #t412 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:251:24: Error: A value of type 'String' can't be assigned to a variable of type 'bool'.
   var list60 = [for (; \"not bool\";) 42];
                        ^" in "not bool" as{TypeError} core::bool*; )
-      #t411.{core::List::add}(42);
+      #t411.{core::List::add}{Invariant}(42);
   } =>#t411;
   core::Set<core::int*>* set60 = block {
     final core::Set<core::int*>* #t413 = col::LinkedHashSet::•<core::int*>();
     for (; let final<BottomType> #t414 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:252:23: Error: A value of type 'String' can't be assigned to a variable of type 'bool'.
   var set60 = {for (; \"not bool\";) 42, null};
                       ^" in "not bool" as{TypeError} core::bool*; )
-      #t413.{core::Set::add}(42);
-    #t413.{core::Set::add}(null);
+      #t413.{core::Set::add}{Invariant}(42);
+    #t413.{core::Set::add}{Invariant}(null);
   } =>#t413;
   core::Map<core::String*, core::int*>* map60 = block {
     final core::Map<core::String*, core::int*>* #t415 = <core::String*, core::int*>{};
     for (; let final<BottomType> #t416 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:253:23: Error: A value of type 'String' can't be assigned to a variable of type 'bool'.
   var map60 = {for (; \"not bool\";) \"bar\": 42, \"baz\": null};
                       ^" in "not bool" as{TypeError} core::bool*; )
-      #t415.{core::Map::[]=}("bar", 42);
-    #t415.{core::Map::[]=}("baz", null);
+      #t415.{core::Map::[]=}{Invariant}("bar", 42);
+    #t415.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t415;
 }
 static method testForElementErrorsNotAsync(asy::Stream<core::int*>* stream) → dynamic {
   block {
     final core::List<core::int*>* #t417 = <core::int*>[];
     await for (core::int* i in stream)
-      #t417.{core::List::add}(i);
+      #t417.{core::List::add}{Invariant}(i);
   } =>#t417;
   block {
     final core::Set<core::int*>* #t418 = col::LinkedHashSet::•<core::int*>();
     await for (core::int* i in stream)
-      #t418.{core::Set::add}(i);
+      #t418.{core::Set::add}{Invariant}(i);
   } =>#t418;
   block {
     final core::Map<core::String*, core::int*>* #t419 = <core::String*, core::int*>{};
     await for (core::int* i in stream)
-      #t419.{core::Map::[]=}("bar", i);
+      #t419.{core::Map::[]=}{Invariant}("bar", i);
   } =>#t419;
 }
 static method testPromotion(self::A* a) → dynamic {
   core::List<core::int*>* list10 = block {
     final core::List<core::int*>* #t420 = <core::int*>[];
     if(a is self::B*)
-      #t420.{core::List::add}(a{self::B*}.{self::B::foo});
+      #t420.{core::List::add}{Invariant}(a{self::B*}.{self::B::foo});
   } =>#t420;
   core::Set<core::int*>* set10 = block {
     final core::Set<core::int*>* #t421 = col::LinkedHashSet::•<core::int*>();
     if(a is self::B*)
-      #t421.{core::Set::add}(a{self::B*}.{self::B::foo});
+      #t421.{core::Set::add}{Invariant}(a{self::B*}.{self::B::foo});
   } =>#t421;
   core::Map<core::int*, core::int*>* map10 = block {
     final core::Map<core::int*, core::int*>* #t422 = <core::int*, core::int*>{};
     if(a is self::B*)
-      #t422.{core::Map::[]=}(a{self::B*}.{self::B::foo}, a{self::B*}.{self::B::foo});
+      #t422.{core::Map::[]=}{Invariant}(a{self::B*}.{self::B::foo}, a{self::B*}.{self::B::foo});
   } =>#t422;
 }
 static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart.weak.transformed.expect b/pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart.weak.transformed.expect
index 82629da..b843b32 100644
--- a/pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart.weak.transformed.expect
@@ -455,53 +455,53 @@
   core::List<core::int*>* list10 = block {
     final core::List<core::int*>* #t1 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t1.{core::List::add}(42);
+      #t1.{core::List::add}{Invariant}(42);
   } =>#t1;
   core::Set<core::int*>* set10 = block {
     final core::Set<core::int*>* #t2 = new col::_CompactLinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t2.{core::Set::add}(42);
-    #t2.{core::Set::add}(null);
+      #t2.{core::Set::add}{Invariant}(42);
+    #t2.{core::Set::add}{Invariant}(null);
   } =>#t2;
   core::Map<core::String*, core::int*>* map10 = block {
     final core::Map<core::String*, core::int*>* #t3 = <core::String*, core::int*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t3.{core::Map::[]=}("bar", 42);
-    #t3.{core::Map::[]=}("baz", null);
+      #t3.{core::Map::[]=}{Invariant}("bar", 42);
+    #t3.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t3;
   core::List<dynamic>* list11 = block {
     final core::List<dynamic>* #t4 = <dynamic>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t4.{core::List::add}(dynVar);
+      #t4.{core::List::add}{Invariant}(dynVar);
   } =>#t4;
   core::Set<dynamic>* set11 = block {
     final core::Set<dynamic>* #t5 = new col::_CompactLinkedHashSet::•<dynamic>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t5.{core::Set::add}(dynVar);
-    #t5.{core::Set::add}(null);
+      #t5.{core::Set::add}{Invariant}(dynVar);
+    #t5.{core::Set::add}{Invariant}(null);
   } =>#t5;
   core::Map<core::String*, dynamic>* map11 = block {
     final core::Map<core::String*, dynamic>* #t6 = <core::String*, dynamic>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t6.{core::Map::[]=}("bar", dynVar);
-    #t6.{core::Map::[]=}("baz", null);
+      #t6.{core::Map::[]=}{Invariant}("bar", dynVar);
+    #t6.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t6;
   core::List<core::List<core::int*>*>* list12 = block {
     final core::List<core::List<core::int*>*>* #t7 = <core::List<core::int*>*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t7.{core::List::add}(<core::int*>[42]);
+      #t7.{core::List::add}{Invariant}(<core::int*>[42]);
   } =>#t7;
   core::Set<core::List<core::int*>*>* set12 = block {
     final core::Set<core::List<core::int*>*>* #t8 = new col::_CompactLinkedHashSet::•<core::List<core::int*>*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t8.{core::Set::add}(<core::int*>[42]);
-    #t8.{core::Set::add}(null);
+      #t8.{core::Set::add}{Invariant}(<core::int*>[42]);
+    #t8.{core::Set::add}{Invariant}(null);
   } =>#t8;
   core::Map<core::String*, core::List<core::int*>*>* map12 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t9 = <core::String*, core::List<core::int*>*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t9.{core::Map::[]=}("bar", <core::int*>[42]);
-    #t9.{core::Map::[]=}("baz", null);
+      #t9.{core::Map::[]=}{Invariant}("bar", <core::int*>[42]);
+    #t9.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t9;
   core::List<core::int*>* list20 = block {
     final core::List<core::int*>* #t10 = <core::int*>[];
@@ -509,7 +509,7 @@
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[42].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t11 = :sync-for-iterator.{core::Iterator::current};
-        #t10.{core::List::add}(#t11);
+        #t10.{core::List::add}{Invariant}(#t11);
       }
     }
   } =>#t10;
@@ -519,10 +519,10 @@
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[42].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t13 = :sync-for-iterator.{core::Iterator::current};
-        #t12.{core::Set::add}(#t13);
+        #t12.{core::Set::add}{Invariant}(#t13);
       }
     }
-    #t12.{core::Set::add}(null);
+    #t12.{core::Set::add}{Invariant}(null);
   } =>#t12;
   core::Map<core::String*, core::int*>* map20 = block {
     final core::Map<core::String*, core::int*>* #t14 = <core::String*, core::int*>{};
@@ -530,10 +530,10 @@
       core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = <core::String*, core::int*>{"bar": 42}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::int*>* #t15 = :sync-for-iterator.{core::Iterator::current};
-        #t14.{core::Map::[]=}(#t15.{core::MapEntry::key}, #t15.{core::MapEntry::value});
+        #t14.{core::Map::[]=}{Invariant}(#t15.{core::MapEntry::key}, #t15.{core::MapEntry::value});
       }
     }
-    #t14.{core::Map::[]=}("baz", null);
+    #t14.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t14;
   core::List<dynamic>* list21 = block {
     final core::List<dynamic>* #t16 = <dynamic>[];
@@ -541,7 +541,7 @@
       core::Iterator<dynamic>* :sync-for-iterator = <dynamic>[dynVar].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final dynamic #t17 = :sync-for-iterator.{core::Iterator::current};
-        #t16.{core::List::add}(#t17);
+        #t16.{core::List::add}{Invariant}(#t17);
       }
     }
   } =>#t16;
@@ -551,10 +551,10 @@
       core::Iterator<dynamic>* :sync-for-iterator = <dynamic>[dynVar].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final dynamic #t19 = :sync-for-iterator.{core::Iterator::current};
-        #t18.{core::Set::add}(#t19);
+        #t18.{core::Set::add}{Invariant}(#t19);
       }
     }
-    #t18.{core::Set::add}(null);
+    #t18.{core::Set::add}{Invariant}(null);
   } =>#t18;
   core::Map<core::String*, dynamic>* map21 = block {
     final core::Map<core::String*, dynamic>* #t20 = <core::String*, dynamic>{};
@@ -562,10 +562,10 @@
       core::Iterator<core::MapEntry<core::String*, dynamic>>* :sync-for-iterator = <core::String*, dynamic>{"bar": dynVar}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, dynamic>* #t21 = :sync-for-iterator.{core::Iterator::current};
-        #t20.{core::Map::[]=}(#t21.{core::MapEntry::key}, #t21.{core::MapEntry::value});
+        #t20.{core::Map::[]=}{Invariant}(#t21.{core::MapEntry::key}, #t21.{core::MapEntry::value});
       }
     }
-    #t20.{core::Map::[]=}("baz", null);
+    #t20.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t20;
   core::List<core::List<core::int*>*>* list22 = block {
     final core::List<core::List<core::int*>*>* #t22 = <core::List<core::int*>*>[];
@@ -573,7 +573,7 @@
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[42]].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t23 = :sync-for-iterator.{core::Iterator::current};
-        #t22.{core::List::add}(#t23);
+        #t22.{core::List::add}{Invariant}(#t23);
       }
     }
   } =>#t22;
@@ -583,10 +583,10 @@
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[42]].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t25 = :sync-for-iterator.{core::Iterator::current};
-        #t24.{core::Set::add}(#t25);
+        #t24.{core::Set::add}{Invariant}(#t25);
       }
     }
-    #t24.{core::Set::add}(null);
+    #t24.{core::Set::add}{Invariant}(null);
   } =>#t24;
   core::Map<core::String*, core::List<core::int*>*>* map22 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t26 = <core::String*, core::List<core::int*>*>{};
@@ -594,10 +594,10 @@
       core::Iterator<core::MapEntry<core::String*, core::List<core::int*>*>>* :sync-for-iterator = <core::String*, core::List<core::int*>*>{"bar": <core::int*>[42]}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::List<core::int*>*>* #t27 = :sync-for-iterator.{core::Iterator::current};
-        #t26.{core::Map::[]=}(#t27.{core::MapEntry::key}, #t27.{core::MapEntry::value});
+        #t26.{core::Map::[]=}{Invariant}(#t27.{core::MapEntry::key}, #t27.{core::MapEntry::value});
       }
     }
-    #t26.{core::Map::[]=}("baz", null);
+    #t26.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t26;
   core::List<core::int*>* list30 = block {
     final core::List<core::int*>* #t28 = <core::int*>[];
@@ -606,7 +606,7 @@
         core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[42].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::int* #t29 = :sync-for-iterator.{core::Iterator::current};
-          #t28.{core::List::add}(#t29);
+          #t28.{core::List::add}{Invariant}(#t29);
         }
       }
   } =>#t28;
@@ -617,10 +617,10 @@
         core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[42].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::int* #t31 = :sync-for-iterator.{core::Iterator::current};
-          #t30.{core::Set::add}(#t31);
+          #t30.{core::Set::add}{Invariant}(#t31);
         }
       }
-    #t30.{core::Set::add}(null);
+    #t30.{core::Set::add}{Invariant}(null);
   } =>#t30;
   core::Map<core::String*, core::int*>* map30 = block {
     final core::Map<core::String*, core::int*>* #t32 = <core::String*, core::int*>{};
@@ -629,10 +629,10 @@
         core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = <core::String*, core::int*>{"bar": 42}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::String*, core::int*>* #t33 = :sync-for-iterator.{core::Iterator::current};
-          #t32.{core::Map::[]=}(#t33.{core::MapEntry::key}, #t33.{core::MapEntry::value});
+          #t32.{core::Map::[]=}{Invariant}(#t33.{core::MapEntry::key}, #t33.{core::MapEntry::value});
         }
       }
-    #t32.{core::Map::[]=}("baz", null);
+    #t32.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t32;
   core::List<dynamic>* list31 = block {
     final core::List<dynamic>* #t34 = <dynamic>[];
@@ -641,7 +641,7 @@
         core::Iterator<dynamic>* :sync-for-iterator = <dynamic>[dynVar].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final dynamic #t35 = :sync-for-iterator.{core::Iterator::current};
-          #t34.{core::List::add}(#t35);
+          #t34.{core::List::add}{Invariant}(#t35);
         }
       }
   } =>#t34;
@@ -652,10 +652,10 @@
         core::Iterator<dynamic>* :sync-for-iterator = <dynamic>[dynVar].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final dynamic #t37 = :sync-for-iterator.{core::Iterator::current};
-          #t36.{core::Set::add}(#t37);
+          #t36.{core::Set::add}{Invariant}(#t37);
         }
       }
-    #t36.{core::Set::add}(null);
+    #t36.{core::Set::add}{Invariant}(null);
   } =>#t36;
   core::Map<core::String*, dynamic>* map31 = block {
     final core::Map<core::String*, dynamic>* #t38 = <core::String*, dynamic>{};
@@ -664,10 +664,10 @@
         core::Iterator<core::MapEntry<core::String*, dynamic>>* :sync-for-iterator = <core::String*, dynamic>{"bar": dynVar}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::String*, dynamic>* #t39 = :sync-for-iterator.{core::Iterator::current};
-          #t38.{core::Map::[]=}(#t39.{core::MapEntry::key}, #t39.{core::MapEntry::value});
+          #t38.{core::Map::[]=}{Invariant}(#t39.{core::MapEntry::key}, #t39.{core::MapEntry::value});
         }
       }
-    #t38.{core::Map::[]=}("baz", null);
+    #t38.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t38;
   core::List<core::List<core::int*>*>* list33 = block {
     final core::List<core::List<core::int*>*>* #t40 = <core::List<core::int*>*>[];
@@ -676,7 +676,7 @@
         core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[42]].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::List<core::int*>* #t41 = :sync-for-iterator.{core::Iterator::current};
-          #t40.{core::List::add}(#t41);
+          #t40.{core::List::add}{Invariant}(#t41);
         }
       }
   } =>#t40;
@@ -687,10 +687,10 @@
         core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[42]].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::List<core::int*>* #t43 = :sync-for-iterator.{core::Iterator::current};
-          #t42.{core::Set::add}(#t43);
+          #t42.{core::Set::add}{Invariant}(#t43);
         }
       }
-    #t42.{core::Set::add}(null);
+    #t42.{core::Set::add}{Invariant}(null);
   } =>#t42;
   core::Map<core::String*, core::List<core::int*>*>* map33 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t44 = <core::String*, core::List<core::int*>*>{};
@@ -699,10 +699,10 @@
         core::Iterator<core::MapEntry<core::String*, core::List<core::int*>*>>* :sync-for-iterator = <core::String*, core::List<core::int*>*>{"bar": <core::int*>[42]}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::String*, core::List<core::int*>*>* #t45 = :sync-for-iterator.{core::Iterator::current};
-          #t44.{core::Map::[]=}(#t45.{core::MapEntry::key}, #t45.{core::MapEntry::value});
+          #t44.{core::Map::[]=}{Invariant}(#t45.{core::MapEntry::key}, #t45.{core::MapEntry::value});
         }
       }
-    #t44.{core::Map::[]=}("baz", null);
+    #t44.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t44;
   core::List<core::List<core::int*>*>* list40 = block {
     final core::List<core::List<core::int*>*>* #t46 = <core::List<core::int*>*>[];
@@ -710,7 +710,7 @@
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t47 = :sync-for-iterator.{core::Iterator::current};
-        #t46.{core::List::add}(#t47);
+        #t46.{core::List::add}{Invariant}(#t47);
       }
     }
   } =>#t46;
@@ -720,10 +720,10 @@
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t49 = :sync-for-iterator.{core::Iterator::current};
-        #t48.{core::Set::add}(#t49);
+        #t48.{core::Set::add}{Invariant}(#t49);
       }
     }
-    #t48.{core::Set::add}(null);
+    #t48.{core::Set::add}{Invariant}(null);
   } =>#t48;
   core::Map<core::String*, core::List<core::int*>*>* map40 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:41:34: Error: Both Iterable and Map spread elements encountered in ambiguous literal.
   Map<String, List<int>> map40 = {if (oracle(\"foo\")) ...{\"bar\", []}, \"baz\": null};
@@ -733,11 +733,11 @@
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*) {
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = ( block {
         final core::Set<core::List<core::int*>*>* #t51 = new col::_CompactLinkedHashSet::•<core::List<core::int*>*>();
-        #t51.{core::Set::add}(<core::int*>[]);
+        #t51.{core::Set::add}{Invariant}(<core::int*>[]);
       } =>#t51).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t52 = :sync-for-iterator.{core::Iterator::current};
-        #t50.{core::List::add}(#t52);
+        #t50.{core::List::add}{Invariant}(#t52);
       }
     }
   } =>#t50;
@@ -746,14 +746,14 @@
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*) {
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = ( block {
         final core::Set<core::List<core::int*>*>* #t54 = new col::_CompactLinkedHashSet::•<core::List<core::int*>*>();
-        #t54.{core::Set::add}(<core::int*>[]);
+        #t54.{core::Set::add}{Invariant}(<core::int*>[]);
       } =>#t54).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t55 = :sync-for-iterator.{core::Iterator::current};
-        #t53.{core::Set::add}(#t55);
+        #t53.{core::Set::add}{Invariant}(#t55);
       }
     }
-    #t53.{core::Set::add}(null);
+    #t53.{core::Set::add}{Invariant}(null);
   } =>#t53;
   core::List<core::List<core::int*>*>* list42 = block {
     final core::List<core::List<core::int*>*>* #t56 = <core::List<core::int*>*>[];
@@ -762,7 +762,7 @@
         core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::List<core::int*>* #t57 = :sync-for-iterator.{core::Iterator::current};
-          #t56.{core::List::add}(#t57);
+          #t56.{core::List::add}{Invariant}(#t57);
         }
       }
   } =>#t56;
@@ -773,10 +773,10 @@
         core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::List<core::int*>* #t59 = :sync-for-iterator.{core::Iterator::current};
-          #t58.{core::Set::add}(#t59);
+          #t58.{core::Set::add}{Invariant}(#t59);
         }
       }
-    #t58.{core::Set::add}(null);
+    #t58.{core::Set::add}{Invariant}(null);
   } =>#t58;
   core::Map<core::String*, core::List<core::int*>*>* map42 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t60 = <core::String*, core::List<core::int*>*>{};
@@ -785,10 +785,10 @@
         core::Iterator<core::MapEntry<core::String*, core::List<core::int*>*>>* :sync-for-iterator = <core::String*, core::List<core::int*>*>{"bar": <core::int*>[]}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::String*, core::List<core::int*>*>* #t61 = :sync-for-iterator.{core::Iterator::current};
-          #t60.{core::Map::[]=}(#t61.{core::MapEntry::key}, #t61.{core::MapEntry::value});
+          #t60.{core::Map::[]=}{Invariant}(#t61.{core::MapEntry::key}, #t61.{core::MapEntry::value});
         }
       }
-    #t60.{core::Map::[]=}("baz", null);
+    #t60.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t60;
   core::List<core::int*>* list50 = block {
     final core::List<core::int*>* #t62 = <core::int*>[];
@@ -796,7 +796,7 @@
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t63 = :sync-for-iterator.{core::Iterator::current};
-        #t62.{core::List::add}(#t63);
+        #t62.{core::List::add}{Invariant}(#t63);
       }
     }
   } =>#t62;
@@ -806,10 +806,10 @@
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t65 = :sync-for-iterator.{core::Iterator::current};
-        #t64.{core::Set::add}(#t65);
+        #t64.{core::Set::add}{Invariant}(#t65);
       }
     }
-    #t64.{core::Set::add}(null);
+    #t64.{core::Set::add}{Invariant}(null);
   } =>#t64;
   core::Map<core::String*, core::int*>* map50 = block {
     final core::Map<core::String*, core::int*>* #t66 = <core::String*, core::int*>{};
@@ -817,10 +817,10 @@
       core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = <core::String*, core::int*>{}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::int*>* #t67 = :sync-for-iterator.{core::Iterator::current};
-        #t66.{core::Map::[]=}(#t67.{core::MapEntry::key}, #t67.{core::MapEntry::value});
+        #t66.{core::Map::[]=}{Invariant}(#t67.{core::MapEntry::key}, #t67.{core::MapEntry::value});
       }
     }
-    #t66.{core::Map::[]=}("baz", null);
+    #t66.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t66;
   core::List<core::int*>* list51 = block {
     final core::List<core::int*>* #t68 = <core::int*>[];
@@ -830,7 +830,7 @@
       } =>#t69).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t70 = :sync-for-iterator.{core::Iterator::current};
-        #t68.{core::List::add}(#t70);
+        #t68.{core::List::add}{Invariant}(#t70);
       }
     }
   } =>#t68;
@@ -842,10 +842,10 @@
       } =>#t72).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t73 = :sync-for-iterator.{core::Iterator::current};
-        #t71.{core::Set::add}(#t73);
+        #t71.{core::Set::add}{Invariant}(#t73);
       }
     }
-    #t71.{core::Set::add}(null);
+    #t71.{core::Set::add}{Invariant}(null);
   } =>#t71;
   core::List<core::int*>* list52 = block {
     final core::List<core::int*>* #t74 = <core::int*>[];
@@ -854,7 +854,7 @@
         core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::int* #t75 = :sync-for-iterator.{core::Iterator::current};
-          #t74.{core::List::add}(#t75);
+          #t74.{core::List::add}{Invariant}(#t75);
         }
       }
   } =>#t74;
@@ -865,10 +865,10 @@
         core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::int* #t77 = :sync-for-iterator.{core::Iterator::current};
-          #t76.{core::Set::add}(#t77);
+          #t76.{core::Set::add}{Invariant}(#t77);
         }
       }
-    #t76.{core::Set::add}(null);
+    #t76.{core::Set::add}{Invariant}(null);
   } =>#t76;
   core::Map<core::String*, core::int*>* map52 = block {
     final core::Map<core::String*, core::int*>* #t78 = <core::String*, core::int*>{};
@@ -877,10 +877,10 @@
         core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = <core::String*, core::int*>{}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::String*, core::int*>* #t79 = :sync-for-iterator.{core::Iterator::current};
-          #t78.{core::Map::[]=}(#t79.{core::MapEntry::key}, #t79.{core::MapEntry::value});
+          #t78.{core::Map::[]=}{Invariant}(#t79.{core::MapEntry::key}, #t79.{core::MapEntry::value});
         }
       }
-    #t78.{core::Map::[]=}("baz", null);
+    #t78.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t78;
   core::List<core::List<core::int*>*>* list60 = block {
     final core::List<core::List<core::int*>*>* #t80 = <core::List<core::int*>*>[];
@@ -888,7 +888,7 @@
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t81 = :sync-for-iterator.{core::Iterator::current};
-        #t80.{core::List::add}(#t81);
+        #t80.{core::List::add}{Invariant}(#t81);
       }
     }
   } =>#t80;
@@ -898,10 +898,10 @@
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t83 = :sync-for-iterator.{core::Iterator::current};
-        #t82.{core::Set::add}(#t83);
+        #t82.{core::Set::add}{Invariant}(#t83);
       }
     }
-    #t82.{core::Set::add}(null);
+    #t82.{core::Set::add}{Invariant}(null);
   } =>#t82;
   core::Map<core::String*, core::List<core::int*>*>* map60 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t84 = <core::String*, core::List<core::int*>*>{};
@@ -909,10 +909,10 @@
       core::Iterator<core::MapEntry<core::String*, core::List<core::int*>*>>* :sync-for-iterator = <core::String*, core::List<core::int*>*>{"bar": <core::int*>[]}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::List<core::int*>*>* #t85 = :sync-for-iterator.{core::Iterator::current};
-        #t84.{core::Map::[]=}(#t85.{core::MapEntry::key}, #t85.{core::MapEntry::value});
+        #t84.{core::Map::[]=}{Invariant}(#t85.{core::MapEntry::key}, #t85.{core::MapEntry::value});
       }
     }
-    #t84.{core::Map::[]=}("baz", null);
+    #t84.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t84;
   core::List<core::List<core::int*>*>* list61 = block {
     final core::List<core::List<core::int*>*>* #t86 = <core::List<core::int*>*>[];
@@ -921,7 +921,7 @@
         core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::List<core::int*>* #t87 = :sync-for-iterator.{core::Iterator::current};
-          #t86.{core::List::add}(#t87);
+          #t86.{core::List::add}{Invariant}(#t87);
         }
       }
   } =>#t86;
@@ -932,10 +932,10 @@
         core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::List<core::int*>* #t89 = :sync-for-iterator.{core::Iterator::current};
-          #t88.{core::Set::add}(#t89);
+          #t88.{core::Set::add}{Invariant}(#t89);
         }
       }
-    #t88.{core::Set::add}(null);
+    #t88.{core::Set::add}{Invariant}(null);
   } =>#t88;
   core::Map<core::String*, core::List<core::int*>*>* map61 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t90 = <core::String*, core::List<core::int*>*>{};
@@ -944,57 +944,57 @@
         core::Iterator<core::MapEntry<core::String*, core::List<core::int*>*>>* :sync-for-iterator = <core::String*, core::List<core::int*>*>{"bar": <core::int*>[]}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::String*, core::List<core::int*>*>* #t91 = :sync-for-iterator.{core::Iterator::current};
-          #t90.{core::Map::[]=}(#t91.{core::MapEntry::key}, #t91.{core::MapEntry::value});
+          #t90.{core::Map::[]=}{Invariant}(#t91.{core::MapEntry::key}, #t91.{core::MapEntry::value});
         }
       }
-    #t90.{core::Map::[]=}("baz", null);
+    #t90.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t90;
   core::List<core::List<core::int*>*>* list70 = block {
     final core::List<core::List<core::int*>*>* #t92 = <core::List<core::int*>*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t92.{core::List::add}(<core::int*>[]);
+      #t92.{core::List::add}{Invariant}(<core::int*>[]);
   } =>#t92;
   core::Set<core::List<core::int*>*>* set70 = block {
     final core::Set<core::List<core::int*>*>* #t93 = new col::_CompactLinkedHashSet::•<core::List<core::int*>*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t93.{core::Set::add}(<core::int*>[]);
-    #t93.{core::Set::add}(null);
+      #t93.{core::Set::add}{Invariant}(<core::int*>[]);
+    #t93.{core::Set::add}{Invariant}(null);
   } =>#t93;
   core::List<core::List<core::int*>*>* list71 = block {
     final core::List<core::List<core::int*>*>* #t94 = <core::List<core::int*>*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t94.{core::List::add}(<core::int*>[]);
+        #t94.{core::List::add}{Invariant}(<core::int*>[]);
   } =>#t94;
   core::Set<core::List<core::int*>*>* set71 = block {
     final core::Set<core::List<core::int*>*>* #t95 = new col::_CompactLinkedHashSet::•<core::List<core::int*>*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t95.{core::Set::add}(<core::int*>[]);
-    #t95.{core::Set::add}(null);
+        #t95.{core::Set::add}{Invariant}(<core::int*>[]);
+    #t95.{core::Set::add}{Invariant}(null);
   } =>#t95;
   core::List<core::num*>* list80 = block {
     final core::List<core::num*>* #t96 = <core::num*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t96.{core::List::add}(42);
+      #t96.{core::List::add}{Invariant}(42);
     else
-      #t96.{core::List::add}(3.14);
+      #t96.{core::List::add}{Invariant}(3.14);
   } =>#t96;
   core::Set<core::num*>* set80 = block {
     final core::Set<core::num*>* #t97 = new col::_CompactLinkedHashSet::•<core::num*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t97.{core::Set::add}(42);
+      #t97.{core::Set::add}{Invariant}(42);
     else
-      #t97.{core::Set::add}(3.14);
-    #t97.{core::Set::add}(null);
+      #t97.{core::Set::add}{Invariant}(3.14);
+    #t97.{core::Set::add}{Invariant}(null);
   } =>#t97;
   core::Map<core::String*, core::num*>* map80 = block {
     final core::Map<core::String*, core::num*>* #t98 = <core::String*, core::num*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t98.{core::Map::[]=}("bar", 42);
+      #t98.{core::Map::[]=}{Invariant}("bar", 42);
     else
-      #t98.{core::Map::[]=}("bar", 3.14);
-    #t98.{core::Map::[]=}("baz", null);
+      #t98.{core::Map::[]=}{Invariant}("bar", 3.14);
+    #t98.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t98;
   core::List<core::num*>* list81 = block {
     final core::List<core::num*>* #t99 = <core::num*>[];
@@ -1002,14 +1002,14 @@
       core::Iterator<core::int*>* :sync-for-iterator = listInt.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::num* #t100 = :sync-for-iterator.{core::Iterator::current};
-        #t99.{core::List::add}(#t100);
+        #t99.{core::List::add}{Invariant}(#t100);
       }
     }
     else {
       core::Iterator<core::double*>* :sync-for-iterator = listDouble.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::num* #t101 = :sync-for-iterator.{core::Iterator::current};
-        #t99.{core::List::add}(#t101);
+        #t99.{core::List::add}{Invariant}(#t101);
       }
     }
   } =>#t99;
@@ -1019,17 +1019,17 @@
       core::Iterator<core::int*>* :sync-for-iterator = listInt.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::num* #t103 = :sync-for-iterator.{core::Iterator::current};
-        #t102.{core::Set::add}(#t103);
+        #t102.{core::Set::add}{Invariant}(#t103);
       }
     }
     else {
       core::Iterator<core::double*>* :sync-for-iterator = listDouble.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::num* #t104 = :sync-for-iterator.{core::Iterator::current};
-        #t102.{core::Set::add}(#t104);
+        #t102.{core::Set::add}{Invariant}(#t104);
       }
     }
-    #t102.{core::Set::add}(null);
+    #t102.{core::Set::add}{Invariant}(null);
   } =>#t102;
   core::Map<core::String*, core::num*>* map81 = block {
     final core::Map<core::String*, core::num*>* #t105 = <core::String*, core::num*>{};
@@ -1037,17 +1037,17 @@
       core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = mapToInt.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::num*>* #t106 = :sync-for-iterator.{core::Iterator::current};
-        #t105.{core::Map::[]=}(#t106.{core::MapEntry::key}, #t106.{core::MapEntry::value});
+        #t105.{core::Map::[]=}{Invariant}(#t106.{core::MapEntry::key}, #t106.{core::MapEntry::value});
       }
     }
     else {
       core::Iterator<core::MapEntry<core::String*, core::double*>>* :sync-for-iterator = mapToDouble.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::num*>* #t107 = :sync-for-iterator.{core::Iterator::current};
-        #t105.{core::Map::[]=}(#t107.{core::MapEntry::key}, #t107.{core::MapEntry::value});
+        #t105.{core::Map::[]=}{Invariant}(#t107.{core::MapEntry::key}, #t107.{core::MapEntry::value});
       }
     }
-    #t105.{core::Map::[]=}("baz", null);
+    #t105.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t105;
   core::List<dynamic>* list82 = block {
     final core::List<dynamic>* #t108 = <dynamic>[];
@@ -1055,14 +1055,14 @@
       core::Iterator<core::int*>* :sync-for-iterator = listInt.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final dynamic #t109 = :sync-for-iterator.{core::Iterator::current};
-        #t108.{core::List::add}(#t109);
+        #t108.{core::List::add}{Invariant}(#t109);
       }
     }
     else {
       core::Iterator<dynamic>* :sync-for-iterator = (dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final dynamic #t110 = :sync-for-iterator.{core::Iterator::current};
-        #t108.{core::List::add}(#t110);
+        #t108.{core::List::add}{Invariant}(#t110);
       }
     }
   } =>#t108;
@@ -1072,22 +1072,22 @@
       core::Iterator<core::int*>* :sync-for-iterator = listInt.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final dynamic #t112 = :sync-for-iterator.{core::Iterator::current};
-        #t111.{core::Set::add}(#t112);
+        #t111.{core::Set::add}{Invariant}(#t112);
       }
     }
     else {
       core::Iterator<dynamic>* :sync-for-iterator = (dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final dynamic #t113 = :sync-for-iterator.{core::Iterator::current};
-        #t111.{core::Set::add}(#t113);
+        #t111.{core::Set::add}{Invariant}(#t113);
       }
     }
-    #t111.{core::Set::add}(null);
+    #t111.{core::Set::add}{Invariant}(null);
   } =>#t111;
   core::Set<dynamic>* map82 = block {
     final core::Set<dynamic>* #t114 = new col::_CompactLinkedHashSet::•<dynamic>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t114.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:73:38: Error: Unexpected type 'Map<String, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t114.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:73:38: Error: Unexpected type 'Map<String, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   var map82 = {if (oracle(\"foo\")) ...mapToInt else ...dynVar, null};
                                      ^");
@@ -1095,20 +1095,20 @@
       core::Iterator<dynamic>* :sync-for-iterator = (dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final dynamic #t115 = :sync-for-iterator.{core::Iterator::current};
-        #t114.{core::Set::add}(#t115);
+        #t114.{core::Set::add}{Invariant}(#t115);
       }
     }
-    #t114.{core::Set::add}(null);
+    #t114.{core::Set::add}{Invariant}(null);
   } =>#t114;
   core::List<core::num*>* list83 = block {
     final core::List<core::num*>* #t116 = <core::num*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t116.{core::List::add}(42);
+      #t116.{core::List::add}{Invariant}(42);
     else {
       core::Iterator<core::double*>* :sync-for-iterator = listDouble.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::num* #t117 = :sync-for-iterator.{core::Iterator::current};
-        #t116.{core::List::add}(#t117);
+        #t116.{core::List::add}{Invariant}(#t117);
       }
     }
   } =>#t116;
@@ -1118,12 +1118,12 @@
       core::Iterator<core::int*>* :sync-for-iterator = listInt.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::num* #t119 = :sync-for-iterator.{core::Iterator::current};
-        #t118.{core::Set::add}(#t119);
+        #t118.{core::Set::add}{Invariant}(#t119);
       }
     }
     else
-      #t118.{core::Set::add}(3.14);
-    #t118.{core::Set::add}(null);
+      #t118.{core::Set::add}{Invariant}(3.14);
+    #t118.{core::Set::add}{Invariant}(null);
   } =>#t118;
   core::Map<core::String*, core::num*>* map83 = block {
     final core::Map<core::String*, core::num*>* #t120 = <core::String*, core::num*>{};
@@ -1131,29 +1131,29 @@
       core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = mapToInt.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::num*>* #t121 = :sync-for-iterator.{core::Iterator::current};
-        #t120.{core::Map::[]=}(#t121.{core::MapEntry::key}, #t121.{core::MapEntry::value});
+        #t120.{core::Map::[]=}{Invariant}(#t121.{core::MapEntry::key}, #t121.{core::MapEntry::value});
       }
     }
     else
-      #t120.{core::Map::[]=}("bar", 3.14);
-    #t120.{core::Map::[]=}("baz", null);
+      #t120.{core::Map::[]=}{Invariant}("bar", 3.14);
+    #t120.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t120;
   core::List<core::int*>* list90 = block {
     final core::List<core::int*>* #t122 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t122.{core::List::add}(dynVar as{TypeError,ForDynamic} core::int*);
+      #t122.{core::List::add}{Invariant}(dynVar as{TypeError,ForDynamic} core::int*);
   } =>#t122;
   core::Set<core::int*>* set90 = block {
     final core::Set<core::int*>* #t123 = new col::_CompactLinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t123.{core::Set::add}(dynVar as{TypeError,ForDynamic} core::int*);
-    #t123.{core::Set::add}(null);
+      #t123.{core::Set::add}{Invariant}(dynVar as{TypeError,ForDynamic} core::int*);
+    #t123.{core::Set::add}{Invariant}(null);
   } =>#t123;
   core::Map<core::String*, core::int*>* map90 = block {
     final core::Map<core::String*, core::int*>* #t124 = <core::String*, core::int*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t124.{core::Map::[]=}("bar", dynVar as{TypeError,ForDynamic} core::int*);
-    #t124.{core::Map::[]=}("baz", null);
+      #t124.{core::Map::[]=}{Invariant}("bar", dynVar as{TypeError,ForDynamic} core::int*);
+    #t124.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t124;
   core::List<core::int*>* list91 = block {
     final core::List<core::int*>* #t125 = <core::int*>[];
@@ -1163,7 +1163,7 @@
         final dynamic #t126 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int* #t127 = #t126 as{TypeError} core::int*;
-          #t125.{core::List::add}(#t127);
+          #t125.{core::List::add}{Invariant}(#t127);
         }
       }
     }
@@ -1176,11 +1176,11 @@
         final dynamic #t129 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int* #t130 = #t129 as{TypeError} core::int*;
-          #t128.{core::Set::add}(#t130);
+          #t128.{core::Set::add}{Invariant}(#t130);
         }
       }
     }
-    #t128.{core::Set::add}(null);
+    #t128.{core::Set::add}{Invariant}(null);
   } =>#t128;
   core::Map<core::String*, core::int*>* map91 = block {
     final core::Map<core::String*, core::int*>* #t131 = <core::String*, core::int*>{};
@@ -1191,51 +1191,51 @@
         {
           final core::String* #t133 = #t132.{core::MapEntry::key} as{TypeError} core::String*;
           final core::int* #t134 = #t132.{core::MapEntry::value} as{TypeError} core::int*;
-          #t131.{core::Map::[]=}(#t133, #t134);
+          #t131.{core::Map::[]=}{Invariant}(#t133, #t134);
         }
       }
     }
-    #t131.{core::Map::[]=}("baz", null);
+    #t131.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t131;
   core::List<core::int*>* list100 = block {
     final core::List<core::int*>* #t135 = <core::int*>[];
     if(dynVar as{TypeError,ForDynamic} core::bool*)
-      #t135.{core::List::add}(42);
+      #t135.{core::List::add}{Invariant}(42);
   } =>#t135;
   core::Set<core::int*>* set100 = block {
     final core::Set<core::int*>* #t136 = new col::_CompactLinkedHashSet::•<core::int*>();
     if(dynVar as{TypeError,ForDynamic} core::bool*)
-      #t136.{core::Set::add}(42);
+      #t136.{core::Set::add}{Invariant}(42);
   } =>#t136;
   core::Map<core::int*, core::int*>* map100 = block {
     final core::Map<core::int*, core::int*>* #t137 = <core::int*, core::int*>{};
     if(dynVar as{TypeError,ForDynamic} core::bool*)
-      #t137.{core::Map::[]=}(42, 42);
+      #t137.{core::Map::[]=}{Invariant}(42, 42);
   } =>#t137;
 }
 static method testIfElementErrors(core::Map<core::int*, core::int*>* map) → dynamic {
   block {
     final core::List<core::int*>* #t138 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t138.{core::List::add}(let final<BottomType> #t139 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:89:28: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+      #t138.{core::List::add}{Invariant}(let final<BottomType> #t139 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:89:28: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int>[if (oracle(\"foo\")) \"bar\"];
                            ^" in "bar" as{TypeError} core::int*);
   } =>#t138;
   block {
     final core::Set<core::int*>* #t140 = new col::_CompactLinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t140.{core::Set::add}(let final<BottomType> #t141 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:90:28: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+      #t140.{core::Set::add}{Invariant}(let final<BottomType> #t141 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:90:28: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int>{if (oracle(\"foo\")) \"bar\", null};
                            ^" in "bar" as{TypeError} core::int*);
-    #t140.{core::Set::add}(null);
+    #t140.{core::Set::add}{Invariant}(null);
   } =>#t140;
   block {
     final core::Map<core::String*, core::int*>* #t142 = <core::String*, core::int*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t142.{core::Map::[]=}("bar", let final<BottomType> #t143 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:91:43: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+      #t142.{core::Map::[]=}{Invariant}("bar", let final<BottomType> #t143 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:91:43: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <String, int>{if (oracle(\"foo\")) \"bar\": \"bar\", \"baz\": null};
                                           ^" in "bar" as{TypeError} core::int*);
-    #t142.{core::Map::[]=}("baz", null);
+    #t142.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t142;
   block {
     final core::List<core::int*>* #t144 = <core::int*>[];
@@ -1245,7 +1245,7 @@
                                ^" in "bar" as{TypeError} core::int*].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t146 = :sync-for-iterator.{core::Iterator::current};
-        #t144.{core::List::add}(#t146);
+        #t144.{core::List::add}{Invariant}(#t146);
       }
     }
   } =>#t144;
@@ -1257,10 +1257,10 @@
                                ^" in "bar" as{TypeError} core::int*].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t149 = :sync-for-iterator.{core::Iterator::current};
-        #t147.{core::Set::add}(#t149);
+        #t147.{core::Set::add}{Invariant}(#t149);
       }
     }
-    #t147.{core::Set::add}(null);
+    #t147.{core::Set::add}{Invariant}(null);
   } =>#t147;
   block {
     final core::Map<core::String*, core::int*>* #t150 = <core::String*, core::int*>{};
@@ -1270,15 +1270,15 @@
                                               ^" in "bar" as{TypeError} core::int*}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::int*>* #t152 = :sync-for-iterator.{core::Iterator::current};
-        #t150.{core::Map::[]=}(#t152.{core::MapEntry::key}, #t152.{core::MapEntry::value});
+        #t150.{core::Map::[]=}{Invariant}(#t152.{core::MapEntry::key}, #t152.{core::MapEntry::value});
       }
     }
-    #t150.{core::Map::[]=}("baz", null);
+    #t150.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t150;
   block {
     final core::List<core::int*>* #t153 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t153.{core::List::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:95:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t153.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:95:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>[if (oracle(\"foo\")) ...map];
                               ^");
@@ -1286,11 +1286,11 @@
   block {
     final core::Set<core::int*>* #t154 = new col::_CompactLinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t154.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:96:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t154.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:96:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>{if (oracle(\"foo\")) ...map, null};
                               ^");
-    #t154.{core::Set::add}(null);
+    #t154.{core::Set::add}{Invariant}(null);
   } =>#t154;
   <core::String*, core::int*>{invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:97:39: Error: Unexpected type 'List<String>' of a map spread entry.  Expected 'dynamic' or a Map.
  - 'List' is from 'dart:core'.
@@ -1302,58 +1302,58 @@
   block {
     final core::List<core::String*>* #t155 = <core::String*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t155.{core::List::add}(let final<BottomType> #t156 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:98:31: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+      #t155.{core::List::add}{Invariant}(let final<BottomType> #t156 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:98:31: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   <String>[if (oracle(\"foo\")) 42 else 3.14];
                               ^" in 42 as{TypeError} core::String*);
     else
-      #t155.{core::List::add}(let final<BottomType> #t157 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:98:39: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
+      #t155.{core::List::add}{Invariant}(let final<BottomType> #t157 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:98:39: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
   <String>[if (oracle(\"foo\")) 42 else 3.14];
                                       ^" in 3.14 as{TypeError} core::String*);
   } =>#t155;
   block {
     final core::Set<core::String*>* #t158 = new col::_CompactLinkedHashSet::•<core::String*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t158.{core::Set::add}(let final<BottomType> #t159 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:99:31: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+      #t158.{core::Set::add}{Invariant}(let final<BottomType> #t159 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:99:31: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   <String>{if (oracle(\"foo\")) 42 else 3.14, null};
                               ^" in 42 as{TypeError} core::String*);
     else
-      #t158.{core::Set::add}(let final<BottomType> #t160 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:99:39: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
+      #t158.{core::Set::add}{Invariant}(let final<BottomType> #t160 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:99:39: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
   <String>{if (oracle(\"foo\")) 42 else 3.14, null};
                                       ^" in 3.14 as{TypeError} core::String*);
-    #t158.{core::Set::add}(null);
+    #t158.{core::Set::add}{Invariant}(null);
   } =>#t158;
   block {
     final core::Map<core::String*, core::String*>* #t161 = <core::String*, core::String*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t161.{core::Map::[]=}("bar", let final<BottomType> #t162 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:100:46: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+      #t161.{core::Map::[]=}{Invariant}("bar", let final<BottomType> #t162 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:100:46: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   <String, String>{if (oracle(\"foo\")) \"bar\": 42 else \"baz\": 3.14, \"baz\": null};
                                              ^" in 42 as{TypeError} core::String*);
     else
-      #t161.{core::Map::[]=}("baz", let final<BottomType> #t163 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:100:61: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
+      #t161.{core::Map::[]=}{Invariant}("baz", let final<BottomType> #t163 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:100:61: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
   <String, String>{if (oracle(\"foo\")) \"bar\": 42 else \"baz\": 3.14, \"baz\": null};
                                                             ^" in 3.14 as{TypeError} core::String*);
-    #t161.{core::Map::[]=}("baz", null);
+    #t161.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t161;
   block {
     final core::List<core::int*>* #t164 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t164.{core::List::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:101:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t164.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:101:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>[if (oracle(\"foo\")) ...map else 42];
                               ^");
     else
-      #t164.{core::List::add}(42);
+      #t164.{core::List::add}{Invariant}(42);
   } =>#t164;
   block {
     final core::Set<core::int*>* #t165 = new col::_CompactLinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t165.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:102:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t165.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:102:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>{if (oracle(\"foo\")) ...map else 42, null};
                               ^");
     else
-      #t165.{core::Set::add}(42);
-    #t165.{core::Set::add}(null);
+      #t165.{core::Set::add}{Invariant}(42);
+    #t165.{core::Set::add}{Invariant}(null);
   } =>#t165;
   <core::String*, core::int*>{invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:103:39: Error: Unexpected type 'List<int>' of a map spread entry.  Expected 'dynamic' or a Map.
  - 'List' is from 'dart:core'.
@@ -1365,9 +1365,9 @@
   block {
     final core::List<core::int*>* #t166 = <core::int*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t166.{core::List::add}(42);
+      #t166.{core::List::add}{Invariant}(42);
     else
-      #t166.{core::List::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:104:39: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t166.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:104:39: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>[if (oracle(\"foo\")) 42 else ...map];
                                       ^");
@@ -1375,13 +1375,13 @@
   block {
     final core::Set<core::int*>* #t167 = new col::_CompactLinkedHashSet::•<core::int*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t167.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:105:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+      #t167.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:105:31: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>{if (oracle(\"foo\")) ...map else 42, null};
                               ^");
     else
-      #t167.{core::Set::add}(42);
-    #t167.{core::Set::add}(null);
+      #t167.{core::Set::add}{Invariant}(42);
+    #t167.{core::Set::add}{Invariant}(null);
   } =>#t167;
   <core::String*, core::int*>{invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:106:54: Error: Unexpected type 'List<int>' of a map spread entry.  Expected 'dynamic' or a Map.
  - 'List' is from 'dart:core'.
@@ -1413,63 +1413,63 @@
     if(let final<BottomType> #t169 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:114:27: Error: A value of type 'int' can't be assigned to a variable of type 'bool'.
   List<int> list20 = [if (42) 42];
                           ^" in 42 as{TypeError} core::bool*)
-      #t168.{core::List::add}(42);
+      #t168.{core::List::add}{Invariant}(42);
   } =>#t168;
   core::Set<core::int*>* set20 = block {
     final core::Set<core::int*>* #t170 = new col::_CompactLinkedHashSet::•<core::int*>();
     if(let final<BottomType> #t171 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:115:25: Error: A value of type 'int' can't be assigned to a variable of type 'bool'.
   Set<int> set20 = {if (42) 42};
                         ^" in 42 as{TypeError} core::bool*)
-      #t170.{core::Set::add}(42);
+      #t170.{core::Set::add}{Invariant}(42);
   } =>#t170;
   core::Map<core::int*, core::int*>* map30 = block {
     final core::Map<core::int*, core::int*>* #t172 = <core::int*, core::int*>{};
     if(let final<BottomType> #t173 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:116:30: Error: A value of type 'int' can't be assigned to a variable of type 'bool'.
   Map<int, int> map30 = {if (42) 42: 42};
                              ^" in 42 as{TypeError} core::bool*)
-      #t172.{core::Map::[]=}(42, 42);
+      #t172.{core::Map::[]=}{Invariant}(42, 42);
   } =>#t172;
   core::List<core::String*>* list40 = block {
     final core::List<core::String*>* #t174 = <core::String*>[];
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t174.{core::List::add}(let final<BottomType> #t175 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:117:53: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
+      #t174.{core::List::add}{Invariant}(let final<BottomType> #t175 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:117:53: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
   List<String> list40 = <String>[if (oracle(\"foo\")) true else 42];
                                                     ^" in true as{TypeError} core::String*);
     else
-      #t174.{core::List::add}(let final<BottomType> #t176 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:117:63: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+      #t174.{core::List::add}{Invariant}(let final<BottomType> #t176 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:117:63: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   List<String> list40 = <String>[if (oracle(\"foo\")) true else 42];
                                                               ^" in 42 as{TypeError} core::String*);
   } =>#t174;
   core::Set<core::String*>* set40 = block {
     final core::Set<core::String*>* #t177 = new col::_CompactLinkedHashSet::•<core::String*>();
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t177.{core::Set::add}(let final<BottomType> #t178 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:118:51: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
+      #t177.{core::Set::add}{Invariant}(let final<BottomType> #t178 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:118:51: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
   Set<String> set40 = <String>{if (oracle(\"foo\")) true else 42};
                                                   ^" in true as{TypeError} core::String*);
     else
-      #t177.{core::Set::add}(let final<BottomType> #t179 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:118:61: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+      #t177.{core::Set::add}{Invariant}(let final<BottomType> #t179 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:118:61: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   Set<String> set40 = <String>{if (oracle(\"foo\")) true else 42};
                                                             ^" in 42 as{TypeError} core::String*);
   } =>#t177;
   core::Map<core::String*, core::int*>* map40 = block {
     final core::Map<core::String*, core::int*>* #t180 = <core::String*, core::int*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t180.{core::Map::[]=}(let final<BottomType> #t181 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:119:61: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
+      #t180.{core::Map::[]=}{Invariant}(let final<BottomType> #t181 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:119:61: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
   Map<String, int> map40 = <String, int>{if (oracle(\"foo\")) true: 42 else 42: 42};
                                                             ^" in true as{TypeError} core::String*, 42);
     else
-      #t180.{core::Map::[]=}(let final<BottomType> #t182 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:119:75: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+      #t180.{core::Map::[]=}{Invariant}(let final<BottomType> #t182 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:119:75: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   Map<String, int> map40 = <String, int>{if (oracle(\"foo\")) true: 42 else 42: 42};
                                                                           ^" in 42 as{TypeError} core::String*, 42);
   } =>#t180;
   core::Map<core::int*, core::String*>* map41 = block {
     final core::Map<core::int*, core::String*>* #t183 = <core::int*, core::String*>{};
     if(self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*)
-      #t183.{core::Map::[]=}(42, let final<BottomType> #t184 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:120:65: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
+      #t183.{core::Map::[]=}{Invariant}(42, let final<BottomType> #t184 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:120:65: Error: A value of type 'bool' can't be assigned to a variable of type 'String'.
   Map<int, String> map41 = <int, String>{if (oracle(\"foo\")) 42: true else 42: 42};
                                                                 ^" in true as{TypeError} core::String*);
     else
-      #t183.{core::Map::[]=}(42, let final<BottomType> #t185 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:120:79: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+      #t183.{core::Map::[]=}{Invariant}(42, let final<BottomType> #t185 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:120:79: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   Map<int, String> map41 = <int, String>{if (oracle(\"foo\")) 42: true else 42: 42};
                                                                               ^" in 42 as{TypeError} core::String*);
   } =>#t183;
@@ -1478,53 +1478,53 @@
   core::List<core::int*>* list10 = block {
     final core::List<core::int*>* #t186 = <core::int*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t186.{core::List::add}(42);
+      #t186.{core::List::add}{Invariant}(42);
   } =>#t186;
   core::Set<core::int*>* set10 = block {
     final core::Set<core::int*>* #t187 = new col::_CompactLinkedHashSet::•<core::int*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t187.{core::Set::add}(42);
-    #t187.{core::Set::add}(null);
+      #t187.{core::Set::add}{Invariant}(42);
+    #t187.{core::Set::add}{Invariant}(null);
   } =>#t187;
   core::Map<core::String*, core::int*>* map10 = block {
     final core::Map<core::String*, core::int*>* #t188 = <core::String*, core::int*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t188.{core::Map::[]=}("bar", 42);
-    #t188.{core::Map::[]=}("baz", null);
+      #t188.{core::Map::[]=}{Invariant}("bar", 42);
+    #t188.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t188;
   core::List<dynamic>* list11 = block {
     final core::List<dynamic>* #t189 = <dynamic>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t189.{core::List::add}(dynVar);
+      #t189.{core::List::add}{Invariant}(dynVar);
   } =>#t189;
   core::Set<dynamic>* set11 = block {
     final core::Set<dynamic>* #t190 = new col::_CompactLinkedHashSet::•<dynamic>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t190.{core::Set::add}(dynVar);
-    #t190.{core::Set::add}(null);
+      #t190.{core::Set::add}{Invariant}(dynVar);
+    #t190.{core::Set::add}{Invariant}(null);
   } =>#t190;
   core::Map<core::String*, dynamic>* map11 = block {
     final core::Map<core::String*, dynamic>* #t191 = <core::String*, dynamic>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t191.{core::Map::[]=}("bar", dynVar);
-    #t191.{core::Map::[]=}("baz", null);
+      #t191.{core::Map::[]=}{Invariant}("bar", dynVar);
+    #t191.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t191;
   core::List<core::List<core::int*>*>* list12 = block {
     final core::List<core::List<core::int*>*>* #t192 = <core::List<core::int*>*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t192.{core::List::add}(<core::int*>[42]);
+      #t192.{core::List::add}{Invariant}(<core::int*>[42]);
   } =>#t192;
   core::Set<core::List<core::int*>*>* set12 = block {
     final core::Set<core::List<core::int*>*>* #t193 = new col::_CompactLinkedHashSet::•<core::List<core::int*>*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t193.{core::Set::add}(<core::int*>[42]);
-    #t193.{core::Set::add}(null);
+      #t193.{core::Set::add}{Invariant}(<core::int*>[42]);
+    #t193.{core::Set::add}{Invariant}(null);
   } =>#t193;
   core::Map<core::String*, core::List<core::int*>*>* map12 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t194 = <core::String*, core::List<core::int*>*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t194.{core::Map::[]=}("bar", <core::int*>[42]);
-    #t194.{core::Map::[]=}("baz", null);
+      #t194.{core::Map::[]=}{Invariant}("bar", <core::int*>[42]);
+    #t194.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t194;
   core::List<core::int*>* list20 = block {
     final core::List<core::int*>* #t195 = <core::int*>[];
@@ -1532,7 +1532,7 @@
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[42].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t196 = :sync-for-iterator.{core::Iterator::current};
-        #t195.{core::List::add}(#t196);
+        #t195.{core::List::add}{Invariant}(#t196);
       }
     }
   } =>#t195;
@@ -1542,10 +1542,10 @@
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[42].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t198 = :sync-for-iterator.{core::Iterator::current};
-        #t197.{core::Set::add}(#t198);
+        #t197.{core::Set::add}{Invariant}(#t198);
       }
     }
-    #t197.{core::Set::add}(null);
+    #t197.{core::Set::add}{Invariant}(null);
   } =>#t197;
   core::Map<core::String*, core::int*>* map20 = block {
     final core::Map<core::String*, core::int*>* #t199 = <core::String*, core::int*>{};
@@ -1553,10 +1553,10 @@
       core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = <core::String*, core::int*>{"bar": 42}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::int*>* #t200 = :sync-for-iterator.{core::Iterator::current};
-        #t199.{core::Map::[]=}(#t200.{core::MapEntry::key}, #t200.{core::MapEntry::value});
+        #t199.{core::Map::[]=}{Invariant}(#t200.{core::MapEntry::key}, #t200.{core::MapEntry::value});
       }
     }
-    #t199.{core::Map::[]=}("baz", null);
+    #t199.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t199;
   core::List<dynamic>* list21 = block {
     final core::List<dynamic>* #t201 = <dynamic>[];
@@ -1564,7 +1564,7 @@
       core::Iterator<dynamic>* :sync-for-iterator = <dynamic>[dynVar].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final dynamic #t202 = :sync-for-iterator.{core::Iterator::current};
-        #t201.{core::List::add}(#t202);
+        #t201.{core::List::add}{Invariant}(#t202);
       }
     }
   } =>#t201;
@@ -1574,10 +1574,10 @@
       core::Iterator<dynamic>* :sync-for-iterator = <dynamic>[dynVar].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final dynamic #t204 = :sync-for-iterator.{core::Iterator::current};
-        #t203.{core::Set::add}(#t204);
+        #t203.{core::Set::add}{Invariant}(#t204);
       }
     }
-    #t203.{core::Set::add}(null);
+    #t203.{core::Set::add}{Invariant}(null);
   } =>#t203;
   core::Map<core::String*, dynamic>* map21 = block {
     final core::Map<core::String*, dynamic>* #t205 = <core::String*, dynamic>{};
@@ -1585,10 +1585,10 @@
       core::Iterator<core::MapEntry<core::String*, dynamic>>* :sync-for-iterator = <core::String*, dynamic>{"bar": dynVar}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, dynamic>* #t206 = :sync-for-iterator.{core::Iterator::current};
-        #t205.{core::Map::[]=}(#t206.{core::MapEntry::key}, #t206.{core::MapEntry::value});
+        #t205.{core::Map::[]=}{Invariant}(#t206.{core::MapEntry::key}, #t206.{core::MapEntry::value});
       }
     }
-    #t205.{core::Map::[]=}("baz", null);
+    #t205.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t205;
   core::List<core::List<core::int*>*>* list22 = block {
     final core::List<core::List<core::int*>*>* #t207 = <core::List<core::int*>*>[];
@@ -1596,7 +1596,7 @@
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[42]].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t208 = :sync-for-iterator.{core::Iterator::current};
-        #t207.{core::List::add}(#t208);
+        #t207.{core::List::add}{Invariant}(#t208);
       }
     }
   } =>#t207;
@@ -1606,10 +1606,10 @@
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[42]].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t210 = :sync-for-iterator.{core::Iterator::current};
-        #t209.{core::Set::add}(#t210);
+        #t209.{core::Set::add}{Invariant}(#t210);
       }
     }
-    #t209.{core::Set::add}(null);
+    #t209.{core::Set::add}{Invariant}(null);
   } =>#t209;
   core::Map<core::String*, core::List<core::int*>*>* map22 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t211 = <core::String*, core::List<core::int*>*>{};
@@ -1617,10 +1617,10 @@
       core::Iterator<core::MapEntry<core::String*, core::List<core::int*>*>>* :sync-for-iterator = <core::String*, core::List<core::int*>*>{"bar": <core::int*>[42]}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::List<core::int*>*>* #t212 = :sync-for-iterator.{core::Iterator::current};
-        #t211.{core::Map::[]=}(#t212.{core::MapEntry::key}, #t212.{core::MapEntry::value});
+        #t211.{core::Map::[]=}{Invariant}(#t212.{core::MapEntry::key}, #t212.{core::MapEntry::value});
       }
     }
-    #t211.{core::Map::[]=}("baz", null);
+    #t211.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t211;
   core::List<core::int*>* list30 = block {
     final core::List<core::int*>* #t213 = <core::int*>[];
@@ -1629,7 +1629,7 @@
         core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[42].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::int* #t214 = :sync-for-iterator.{core::Iterator::current};
-          #t213.{core::List::add}(#t214);
+          #t213.{core::List::add}{Invariant}(#t214);
         }
       }
   } =>#t213;
@@ -1640,10 +1640,10 @@
         core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[42].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::int* #t216 = :sync-for-iterator.{core::Iterator::current};
-          #t215.{core::Set::add}(#t216);
+          #t215.{core::Set::add}{Invariant}(#t216);
         }
       }
-    #t215.{core::Set::add}(null);
+    #t215.{core::Set::add}{Invariant}(null);
   } =>#t215;
   core::Map<core::String*, core::int*>* map30 = block {
     final core::Map<core::String*, core::int*>* #t217 = <core::String*, core::int*>{};
@@ -1652,10 +1652,10 @@
         core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = <core::String*, core::int*>{"bar": 42}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::String*, core::int*>* #t218 = :sync-for-iterator.{core::Iterator::current};
-          #t217.{core::Map::[]=}(#t218.{core::MapEntry::key}, #t218.{core::MapEntry::value});
+          #t217.{core::Map::[]=}{Invariant}(#t218.{core::MapEntry::key}, #t218.{core::MapEntry::value});
         }
       }
-    #t217.{core::Map::[]=}("baz", null);
+    #t217.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t217;
   core::List<dynamic>* list31 = block {
     final core::List<dynamic>* #t219 = <dynamic>[];
@@ -1664,7 +1664,7 @@
         core::Iterator<dynamic>* :sync-for-iterator = <dynamic>[dynVar].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final dynamic #t220 = :sync-for-iterator.{core::Iterator::current};
-          #t219.{core::List::add}(#t220);
+          #t219.{core::List::add}{Invariant}(#t220);
         }
       }
   } =>#t219;
@@ -1675,10 +1675,10 @@
         core::Iterator<dynamic>* :sync-for-iterator = <dynamic>[dynVar].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final dynamic #t222 = :sync-for-iterator.{core::Iterator::current};
-          #t221.{core::Set::add}(#t222);
+          #t221.{core::Set::add}{Invariant}(#t222);
         }
       }
-    #t221.{core::Set::add}(null);
+    #t221.{core::Set::add}{Invariant}(null);
   } =>#t221;
   core::Map<core::String*, dynamic>* map31 = block {
     final core::Map<core::String*, dynamic>* #t223 = <core::String*, dynamic>{};
@@ -1687,10 +1687,10 @@
         core::Iterator<core::MapEntry<core::String*, dynamic>>* :sync-for-iterator = <core::String*, dynamic>{"bar": dynVar}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::String*, dynamic>* #t224 = :sync-for-iterator.{core::Iterator::current};
-          #t223.{core::Map::[]=}(#t224.{core::MapEntry::key}, #t224.{core::MapEntry::value});
+          #t223.{core::Map::[]=}{Invariant}(#t224.{core::MapEntry::key}, #t224.{core::MapEntry::value});
         }
       }
-    #t223.{core::Map::[]=}("baz", null);
+    #t223.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t223;
   core::List<core::List<core::int*>*>* list33 = block {
     final core::List<core::List<core::int*>*>* #t225 = <core::List<core::int*>*>[];
@@ -1699,7 +1699,7 @@
         core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[42]].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::List<core::int*>* #t226 = :sync-for-iterator.{core::Iterator::current};
-          #t225.{core::List::add}(#t226);
+          #t225.{core::List::add}{Invariant}(#t226);
         }
       }
   } =>#t225;
@@ -1710,10 +1710,10 @@
         core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[42]].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::List<core::int*>* #t228 = :sync-for-iterator.{core::Iterator::current};
-          #t227.{core::Set::add}(#t228);
+          #t227.{core::Set::add}{Invariant}(#t228);
         }
       }
-    #t227.{core::Set::add}(null);
+    #t227.{core::Set::add}{Invariant}(null);
   } =>#t227;
   core::Map<core::String*, core::List<core::int*>*>* map33 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t229 = <core::String*, core::List<core::int*>*>{};
@@ -1722,10 +1722,10 @@
         core::Iterator<core::MapEntry<core::String*, core::List<core::int*>*>>* :sync-for-iterator = <core::String*, core::List<core::int*>*>{"bar": <core::int*>[42]}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::String*, core::List<core::int*>*>* #t230 = :sync-for-iterator.{core::Iterator::current};
-          #t229.{core::Map::[]=}(#t230.{core::MapEntry::key}, #t230.{core::MapEntry::value});
+          #t229.{core::Map::[]=}{Invariant}(#t230.{core::MapEntry::key}, #t230.{core::MapEntry::value});
         }
       }
-    #t229.{core::Map::[]=}("baz", null);
+    #t229.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t229;
   core::List<core::List<core::int*>*>* list40 = block {
     final core::List<core::List<core::int*>*>* #t231 = <core::List<core::int*>*>[];
@@ -1733,7 +1733,7 @@
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t232 = :sync-for-iterator.{core::Iterator::current};
-        #t231.{core::List::add}(#t232);
+        #t231.{core::List::add}{Invariant}(#t232);
       }
     }
   } =>#t231;
@@ -1743,10 +1743,10 @@
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t234 = :sync-for-iterator.{core::Iterator::current};
-        #t233.{core::Set::add}(#t234);
+        #t233.{core::Set::add}{Invariant}(#t234);
       }
     }
-    #t233.{core::Set::add}(null);
+    #t233.{core::Set::add}{Invariant}(null);
   } =>#t233;
   core::Map<core::String*, core::List<core::int*>*>* map40 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t235 = <core::String*, core::List<core::int*>*>{};
@@ -1754,21 +1754,21 @@
       core::Iterator<core::MapEntry<core::String*, core::List<core::int*>*>>* :sync-for-iterator = <core::String*, core::List<core::int*>*>{"bar": <core::int*>[]}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::List<core::int*>*>* #t236 = :sync-for-iterator.{core::Iterator::current};
-        #t235.{core::Map::[]=}(#t236.{core::MapEntry::key}, #t236.{core::MapEntry::value});
+        #t235.{core::Map::[]=}{Invariant}(#t236.{core::MapEntry::key}, #t236.{core::MapEntry::value});
       }
     }
-    #t235.{core::Map::[]=}("baz", null);
+    #t235.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t235;
   core::List<core::List<core::int*>*>* list41 = block {
     final core::List<core::List<core::int*>*>* #t237 = <core::List<core::int*>*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1)) {
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = ( block {
         final core::Set<core::List<core::int*>*>* #t238 = new col::_CompactLinkedHashSet::•<core::List<core::int*>*>();
-        #t238.{core::Set::add}(<core::int*>[]);
+        #t238.{core::Set::add}{Invariant}(<core::int*>[]);
       } =>#t238).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t239 = :sync-for-iterator.{core::Iterator::current};
-        #t237.{core::List::add}(#t239);
+        #t237.{core::List::add}{Invariant}(#t239);
       }
     }
   } =>#t237;
@@ -1777,14 +1777,14 @@
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1)) {
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = ( block {
         final core::Set<core::List<core::int*>*>* #t241 = new col::_CompactLinkedHashSet::•<core::List<core::int*>*>();
-        #t241.{core::Set::add}(<core::int*>[]);
+        #t241.{core::Set::add}{Invariant}(<core::int*>[]);
       } =>#t241).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t242 = :sync-for-iterator.{core::Iterator::current};
-        #t240.{core::Set::add}(#t242);
+        #t240.{core::Set::add}{Invariant}(#t242);
       }
     }
-    #t240.{core::Set::add}(null);
+    #t240.{core::Set::add}{Invariant}(null);
   } =>#t240;
   core::List<core::List<core::int*>*>* list42 = block {
     final core::List<core::List<core::int*>*>* #t243 = <core::List<core::int*>*>[];
@@ -1793,7 +1793,7 @@
         core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::List<core::int*>* #t244 = :sync-for-iterator.{core::Iterator::current};
-          #t243.{core::List::add}(#t244);
+          #t243.{core::List::add}{Invariant}(#t244);
         }
       }
   } =>#t243;
@@ -1804,10 +1804,10 @@
         core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::List<core::int*>* #t246 = :sync-for-iterator.{core::Iterator::current};
-          #t245.{core::Set::add}(#t246);
+          #t245.{core::Set::add}{Invariant}(#t246);
         }
       }
-    #t245.{core::Set::add}(null);
+    #t245.{core::Set::add}{Invariant}(null);
   } =>#t245;
   core::Map<core::String*, core::List<core::int*>*>* map42 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t247 = <core::String*, core::List<core::int*>*>{};
@@ -1816,10 +1816,10 @@
         core::Iterator<core::MapEntry<core::String*, core::List<core::int*>*>>* :sync-for-iterator = <core::String*, core::List<core::int*>*>{"bar": <core::int*>[]}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::String*, core::List<core::int*>*>* #t248 = :sync-for-iterator.{core::Iterator::current};
-          #t247.{core::Map::[]=}(#t248.{core::MapEntry::key}, #t248.{core::MapEntry::value});
+          #t247.{core::Map::[]=}{Invariant}(#t248.{core::MapEntry::key}, #t248.{core::MapEntry::value});
         }
       }
-    #t247.{core::Map::[]=}("baz", null);
+    #t247.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t247;
   core::List<core::int*>* list50 = block {
     final core::List<core::int*>* #t249 = <core::int*>[];
@@ -1827,7 +1827,7 @@
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t250 = :sync-for-iterator.{core::Iterator::current};
-        #t249.{core::List::add}(#t250);
+        #t249.{core::List::add}{Invariant}(#t250);
       }
     }
   } =>#t249;
@@ -1837,10 +1837,10 @@
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t252 = :sync-for-iterator.{core::Iterator::current};
-        #t251.{core::Set::add}(#t252);
+        #t251.{core::Set::add}{Invariant}(#t252);
       }
     }
-    #t251.{core::Set::add}(null);
+    #t251.{core::Set::add}{Invariant}(null);
   } =>#t251;
   core::Map<core::String*, core::int*>* map50 = block {
     final core::Map<core::String*, core::int*>* #t253 = <core::String*, core::int*>{};
@@ -1848,10 +1848,10 @@
       core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = <core::String*, core::int*>{}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::int*>* #t254 = :sync-for-iterator.{core::Iterator::current};
-        #t253.{core::Map::[]=}(#t254.{core::MapEntry::key}, #t254.{core::MapEntry::value});
+        #t253.{core::Map::[]=}{Invariant}(#t254.{core::MapEntry::key}, #t254.{core::MapEntry::value});
       }
     }
-    #t253.{core::Map::[]=}("baz", null);
+    #t253.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t253;
   core::List<core::int*>* list51 = block {
     final core::List<core::int*>* #t255 = <core::int*>[];
@@ -1861,7 +1861,7 @@
       } =>#t256).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t257 = :sync-for-iterator.{core::Iterator::current};
-        #t255.{core::List::add}(#t257);
+        #t255.{core::List::add}{Invariant}(#t257);
       }
     }
   } =>#t255;
@@ -1873,10 +1873,10 @@
       } =>#t259).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t260 = :sync-for-iterator.{core::Iterator::current};
-        #t258.{core::Set::add}(#t260);
+        #t258.{core::Set::add}{Invariant}(#t260);
       }
     }
-    #t258.{core::Set::add}(null);
+    #t258.{core::Set::add}{Invariant}(null);
   } =>#t258;
   core::List<core::int*>* list52 = block {
     final core::List<core::int*>* #t261 = <core::int*>[];
@@ -1885,7 +1885,7 @@
         core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::int* #t262 = :sync-for-iterator.{core::Iterator::current};
-          #t261.{core::List::add}(#t262);
+          #t261.{core::List::add}{Invariant}(#t262);
         }
       }
   } =>#t261;
@@ -1896,10 +1896,10 @@
         core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::int* #t264 = :sync-for-iterator.{core::Iterator::current};
-          #t263.{core::Set::add}(#t264);
+          #t263.{core::Set::add}{Invariant}(#t264);
         }
       }
-    #t263.{core::Set::add}(null);
+    #t263.{core::Set::add}{Invariant}(null);
   } =>#t263;
   core::List<core::List<core::int*>*>* list60 = block {
     final core::List<core::List<core::int*>*>* #t265 = <core::List<core::int*>*>[];
@@ -1907,7 +1907,7 @@
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t266 = :sync-for-iterator.{core::Iterator::current};
-        #t265.{core::List::add}(#t266);
+        #t265.{core::List::add}{Invariant}(#t266);
       }
     }
   } =>#t265;
@@ -1917,10 +1917,10 @@
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t268 = :sync-for-iterator.{core::Iterator::current};
-        #t267.{core::Set::add}(#t268);
+        #t267.{core::Set::add}{Invariant}(#t268);
       }
     }
-    #t267.{core::Set::add}(null);
+    #t267.{core::Set::add}{Invariant}(null);
   } =>#t267;
   core::Map<core::String*, core::List<core::int*>*>* map60 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t269 = <core::String*, core::List<core::int*>*>{};
@@ -1928,10 +1928,10 @@
       core::Iterator<core::MapEntry<core::String*, core::List<core::int*>*>>* :sync-for-iterator = <core::String*, core::List<core::int*>*>{"bar": <core::int*>[]}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::List<core::int*>*>* #t270 = :sync-for-iterator.{core::Iterator::current};
-        #t269.{core::Map::[]=}(#t270.{core::MapEntry::key}, #t270.{core::MapEntry::value});
+        #t269.{core::Map::[]=}{Invariant}(#t270.{core::MapEntry::key}, #t270.{core::MapEntry::value});
       }
     }
-    #t269.{core::Map::[]=}("baz", null);
+    #t269.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t269;
   core::List<core::List<core::int*>*>* list61 = block {
     final core::List<core::List<core::int*>*>* #t271 = <core::List<core::int*>*>[];
@@ -1940,7 +1940,7 @@
         core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::List<core::int*>* #t272 = :sync-for-iterator.{core::Iterator::current};
-          #t271.{core::List::add}(#t272);
+          #t271.{core::List::add}{Invariant}(#t272);
         }
       }
   } =>#t271;
@@ -1951,10 +1951,10 @@
         core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::List<core::int*>* #t274 = :sync-for-iterator.{core::Iterator::current};
-          #t273.{core::Set::add}(#t274);
+          #t273.{core::Set::add}{Invariant}(#t274);
         }
       }
-    #t273.{core::Set::add}(null);
+    #t273.{core::Set::add}{Invariant}(null);
   } =>#t273;
   core::Map<core::String*, core::List<core::int*>*>* map61 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t275 = <core::String*, core::List<core::int*>*>{};
@@ -1963,73 +1963,73 @@
         core::Iterator<core::MapEntry<core::String*, core::List<core::int*>*>>* :sync-for-iterator = <core::String*, core::List<core::int*>*>{"bar": <core::int*>[]}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::String*, core::List<core::int*>*>* #t276 = :sync-for-iterator.{core::Iterator::current};
-          #t275.{core::Map::[]=}(#t276.{core::MapEntry::key}, #t276.{core::MapEntry::value});
+          #t275.{core::Map::[]=}{Invariant}(#t276.{core::MapEntry::key}, #t276.{core::MapEntry::value});
         }
       }
-    #t275.{core::Map::[]=}("baz", null);
+    #t275.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t275;
   core::List<core::List<core::int*>*>* list70 = block {
     final core::List<core::List<core::int*>*>* #t277 = <core::List<core::int*>*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t277.{core::List::add}(<core::int*>[]);
+      #t277.{core::List::add}{Invariant}(<core::int*>[]);
   } =>#t277;
   core::Set<core::List<core::int*>*>* set70 = block {
     final core::Set<core::List<core::int*>*>* #t278 = new col::_CompactLinkedHashSet::•<core::List<core::int*>*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t278.{core::Set::add}(<core::int*>[]);
-    #t278.{core::Set::add}(null);
+      #t278.{core::Set::add}{Invariant}(<core::int*>[]);
+    #t278.{core::Set::add}{Invariant}(null);
   } =>#t278;
   core::Map<core::String*, core::List<core::int*>*>* map70 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t279 = <core::String*, core::List<core::int*>*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t279.{core::Map::[]=}("bar", <core::int*>[]);
-    #t279.{core::Map::[]=}("baz", null);
+      #t279.{core::Map::[]=}{Invariant}("bar", <core::int*>[]);
+    #t279.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t279;
   core::List<core::List<core::int*>*>* list71 = block {
     final core::List<core::List<core::int*>*>* #t280 = <core::List<core::int*>*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t280.{core::List::add}(<core::int*>[]);
+        #t280.{core::List::add}{Invariant}(<core::int*>[]);
   } =>#t280;
   core::Set<core::List<core::int*>*>* set71 = block {
     final core::Set<core::List<core::int*>*>* #t281 = new col::_CompactLinkedHashSet::•<core::List<core::int*>*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t281.{core::Set::add}(<core::int*>[]);
-    #t281.{core::Set::add}(null);
+        #t281.{core::Set::add}{Invariant}(<core::int*>[]);
+    #t281.{core::Set::add}{Invariant}(null);
   } =>#t281;
   core::Map<core::String*, core::List<core::int*>*>* map71 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t282 = <core::String*, core::List<core::int*>*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t282.{core::Map::[]=}("bar", <core::int*>[]);
-    #t282.{core::Map::[]=}("baz", null);
+        #t282.{core::Map::[]=}{Invariant}("bar", <core::int*>[]);
+    #t282.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t282;
   core::List<core::num*>* list80 = block {
     final core::List<core::num*>* #t283 = <core::num*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t283.{core::List::add}(42);
+        #t283.{core::List::add}{Invariant}(42);
       else
-        #t283.{core::List::add}(3.14);
+        #t283.{core::List::add}{Invariant}(3.14);
   } =>#t283;
   core::Set<core::num*>* set80 = block {
     final core::Set<core::num*>* #t284 = new col::_CompactLinkedHashSet::•<core::num*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t284.{core::Set::add}(42);
+        #t284.{core::Set::add}{Invariant}(42);
       else
-        #t284.{core::Set::add}(3.14);
-    #t284.{core::Set::add}(null);
+        #t284.{core::Set::add}{Invariant}(3.14);
+    #t284.{core::Set::add}{Invariant}(null);
   } =>#t284;
   core::Map<core::String*, core::num*>* map80 = block {
     final core::Map<core::String*, core::num*>* #t285 = <core::String*, core::num*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t285.{core::Map::[]=}("bar", 42);
+        #t285.{core::Map::[]=}{Invariant}("bar", 42);
       else
-        #t285.{core::Map::[]=}("bar", 3.14);
-    #t285.{core::Map::[]=}("baz", null);
+        #t285.{core::Map::[]=}{Invariant}("bar", 3.14);
+    #t285.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t285;
   core::List<core::num*>* list81 = block {
     final core::List<core::num*>* #t286 = <core::num*>[];
@@ -2038,14 +2038,14 @@
         core::Iterator<core::int*>* :sync-for-iterator = listInt.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::num* #t287 = :sync-for-iterator.{core::Iterator::current};
-          #t286.{core::List::add}(#t287);
+          #t286.{core::List::add}{Invariant}(#t287);
         }
       }
       else {
         core::Iterator<core::double*>* :sync-for-iterator = listDouble.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::num* #t288 = :sync-for-iterator.{core::Iterator::current};
-          #t286.{core::List::add}(#t288);
+          #t286.{core::List::add}{Invariant}(#t288);
         }
       }
   } =>#t286;
@@ -2056,17 +2056,17 @@
         core::Iterator<core::int*>* :sync-for-iterator = listInt.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::num* #t290 = :sync-for-iterator.{core::Iterator::current};
-          #t289.{core::Set::add}(#t290);
+          #t289.{core::Set::add}{Invariant}(#t290);
         }
       }
       else {
         core::Iterator<core::double*>* :sync-for-iterator = listDouble.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::num* #t291 = :sync-for-iterator.{core::Iterator::current};
-          #t289.{core::Set::add}(#t291);
+          #t289.{core::Set::add}{Invariant}(#t291);
         }
       }
-    #t289.{core::Set::add}(null);
+    #t289.{core::Set::add}{Invariant}(null);
   } =>#t289;
   core::Map<core::String*, core::num*>* map81 = block {
     final core::Map<core::String*, core::num*>* #t292 = <core::String*, core::num*>{};
@@ -2075,17 +2075,17 @@
         core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = mapStringInt.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::String*, core::num*>* #t293 = :sync-for-iterator.{core::Iterator::current};
-          #t292.{core::Map::[]=}(#t293.{core::MapEntry::key}, #t293.{core::MapEntry::value});
+          #t292.{core::Map::[]=}{Invariant}(#t293.{core::MapEntry::key}, #t293.{core::MapEntry::value});
         }
       }
       else {
         core::Iterator<core::MapEntry<core::String*, core::double*>>* :sync-for-iterator = mapStringDouble.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::String*, core::num*>* #t294 = :sync-for-iterator.{core::Iterator::current};
-          #t292.{core::Map::[]=}(#t294.{core::MapEntry::key}, #t294.{core::MapEntry::value});
+          #t292.{core::Map::[]=}{Invariant}(#t294.{core::MapEntry::key}, #t294.{core::MapEntry::value});
         }
       }
-    #t292.{core::Map::[]=}("baz", null);
+    #t292.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t292;
   core::List<dynamic>* list82 = block {
     final core::List<dynamic>* #t295 = <dynamic>[];
@@ -2094,14 +2094,14 @@
         core::Iterator<core::int*>* :sync-for-iterator = listInt.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final dynamic #t296 = :sync-for-iterator.{core::Iterator::current};
-          #t295.{core::List::add}(#t296);
+          #t295.{core::List::add}{Invariant}(#t296);
         }
       }
       else {
         core::Iterator<dynamic>* :sync-for-iterator = (dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*).{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final dynamic #t297 = :sync-for-iterator.{core::Iterator::current};
-          #t295.{core::List::add}(#t297);
+          #t295.{core::List::add}{Invariant}(#t297);
         }
       }
   } =>#t295;
@@ -2112,17 +2112,17 @@
         core::Iterator<core::int*>* :sync-for-iterator = listInt.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final dynamic #t299 = :sync-for-iterator.{core::Iterator::current};
-          #t298.{core::Set::add}(#t299);
+          #t298.{core::Set::add}{Invariant}(#t299);
         }
       }
       else {
         core::Iterator<dynamic>* :sync-for-iterator = (dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*).{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final dynamic #t300 = :sync-for-iterator.{core::Iterator::current};
-          #t298.{core::Set::add}(#t300);
+          #t298.{core::Set::add}{Invariant}(#t300);
         }
       }
-    #t298.{core::Set::add}(null);
+    #t298.{core::Set::add}{Invariant}(null);
   } =>#t298;
   core::Map<dynamic, dynamic>* map82 = block {
     final core::Map<dynamic, dynamic>* #t301 = <dynamic, dynamic>{};
@@ -2131,28 +2131,28 @@
         core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = mapStringInt.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<dynamic, dynamic>* #t302 = :sync-for-iterator.{core::Iterator::current};
-          #t301.{core::Map::[]=}(#t302.{core::MapEntry::key}, #t302.{core::MapEntry::value});
+          #t301.{core::Map::[]=}{Invariant}(#t302.{core::MapEntry::key}, #t302.{core::MapEntry::value});
         }
       }
       else {
         core::Iterator<core::MapEntry<dynamic, dynamic>>* :sync-for-iterator = (dynVar as{TypeError,ForDynamic} core::Map<dynamic, dynamic>*).{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<dynamic, dynamic>* #t303 = :sync-for-iterator.{core::Iterator::current};
-          #t301.{core::Map::[]=}(#t303.{core::MapEntry::key}, #t303.{core::MapEntry::value});
+          #t301.{core::Map::[]=}{Invariant}(#t303.{core::MapEntry::key}, #t303.{core::MapEntry::value});
         }
       }
-    #t301.{core::Map::[]=}("baz", null);
+    #t301.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t301;
   core::List<core::num*>* list83 = block {
     final core::List<core::num*>* #t304 = <core::num*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
       if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-        #t304.{core::List::add}(42);
+        #t304.{core::List::add}{Invariant}(42);
       else {
         core::Iterator<core::double*>* :sync-for-iterator = listDouble.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::num* #t305 = :sync-for-iterator.{core::Iterator::current};
-          #t304.{core::List::add}(#t305);
+          #t304.{core::List::add}{Invariant}(#t305);
         }
       }
   } =>#t304;
@@ -2163,12 +2163,12 @@
         core::Iterator<core::int*>* :sync-for-iterator = listInt.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::num* #t307 = :sync-for-iterator.{core::Iterator::current};
-          #t306.{core::Set::add}(#t307);
+          #t306.{core::Set::add}{Invariant}(#t307);
         }
       }
       else
-        #t306.{core::Set::add}(3.14);
-    #t306.{core::Set::add}(null);
+        #t306.{core::Set::add}{Invariant}(3.14);
+    #t306.{core::Set::add}{Invariant}(null);
   } =>#t306;
   core::Map<core::String*, core::num*>* map83 = block {
     final core::Map<core::String*, core::num*>* #t308 = <core::String*, core::num*>{};
@@ -2177,29 +2177,29 @@
         core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = mapStringInt.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::String*, core::num*>* #t309 = :sync-for-iterator.{core::Iterator::current};
-          #t308.{core::Map::[]=}(#t309.{core::MapEntry::key}, #t309.{core::MapEntry::value});
+          #t308.{core::Map::[]=}{Invariant}(#t309.{core::MapEntry::key}, #t309.{core::MapEntry::value});
         }
       }
       else
-        #t308.{core::Map::[]=}("bar", 3.14);
-    #t308.{core::Map::[]=}("baz", null);
+        #t308.{core::Map::[]=}{Invariant}("bar", 3.14);
+    #t308.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t308;
   core::List<core::int*>* list90 = block {
     final core::List<core::int*>* #t310 = <core::int*>[];
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t310.{core::List::add}(dynVar as{TypeError,ForDynamic} core::int*);
+      #t310.{core::List::add}{Invariant}(dynVar as{TypeError,ForDynamic} core::int*);
   } =>#t310;
   core::Set<core::int*>* set90 = block {
     final core::Set<core::int*>* #t311 = new col::_CompactLinkedHashSet::•<core::int*>();
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t311.{core::Set::add}(dynVar as{TypeError,ForDynamic} core::int*);
-    #t311.{core::Set::add}(null);
+      #t311.{core::Set::add}{Invariant}(dynVar as{TypeError,ForDynamic} core::int*);
+    #t311.{core::Set::add}{Invariant}(null);
   } =>#t311;
   core::Map<core::String*, core::int*>* map90 = block {
     final core::Map<core::String*, core::int*>* #t312 = <core::String*, core::int*>{};
     for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-      #t312.{core::Map::[]=}("bar", dynVar as{TypeError,ForDynamic} core::int*);
-    #t312.{core::Map::[]=}("baz", null);
+      #t312.{core::Map::[]=}{Invariant}("bar", dynVar as{TypeError,ForDynamic} core::int*);
+    #t312.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t312;
   core::List<core::int*>* list91 = block {
     final core::List<core::int*>* #t313 = <core::int*>[];
@@ -2209,7 +2209,7 @@
         final dynamic #t314 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int* #t315 = #t314 as{TypeError} core::int*;
-          #t313.{core::List::add}(#t315);
+          #t313.{core::List::add}{Invariant}(#t315);
         }
       }
     }
@@ -2222,11 +2222,11 @@
         final dynamic #t317 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int* #t318 = #t317 as{TypeError} core::int*;
-          #t316.{core::Set::add}(#t318);
+          #t316.{core::Set::add}{Invariant}(#t318);
         }
       }
     }
-    #t316.{core::Set::add}(null);
+    #t316.{core::Set::add}{Invariant}(null);
   } =>#t316;
   core::Map<core::String*, core::int*>* map91 = block {
     final core::Map<core::String*, core::int*>* #t319 = <core::String*, core::int*>{};
@@ -2237,26 +2237,26 @@
         {
           final core::String* #t321 = #t320.{core::MapEntry::key} as{TypeError} core::String*;
           final core::int* #t322 = #t320.{core::MapEntry::value} as{TypeError} core::int*;
-          #t319.{core::Map::[]=}(#t321, #t322);
+          #t319.{core::Map::[]=}{Invariant}(#t321, #t322);
         }
       }
     }
-    #t319.{core::Map::[]=}("baz", null);
+    #t319.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t319;
   core::List<core::int*>* list100 = block {
     final core::List<core::int*>* #t323 = <core::int*>[];
     for (final core::int* #t324 = index = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; index = index.{core::num::+}(1))
-      #t323.{core::List::add}(42);
+      #t323.{core::List::add}{Invariant}(42);
   } =>#t323;
   core::Set<core::int*>* set100 = block {
     final core::Set<core::int*>* #t325 = new col::_CompactLinkedHashSet::•<core::int*>();
     for (final core::int* #t326 = index = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; index = index.{core::num::+}(1))
-      #t325.{core::Set::add}(42);
+      #t325.{core::Set::add}{Invariant}(42);
   } =>#t325;
   core::Map<core::String*, core::int*>* map100 = block {
     final core::Map<core::String*, core::int*>* #t327 = <core::String*, core::int*>{};
     for (final core::int* #t328 = index = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; index = index.{core::num::+}(1))
-      #t327.{core::Map::[]=}("bar", 42);
+      #t327.{core::Map::[]=}{Invariant}("bar", 42);
   } =>#t327;
   core::List<core::int*>* list110 = block {
     final core::List<core::int*>* #t329 = <core::int*>[];
@@ -2264,7 +2264,7 @@
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[1, 2, 3].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         core::int* i = :sync-for-iterator.{core::Iterator::current};
-        #t329.{core::List::add}(i);
+        #t329.{core::List::add}{Invariant}(i);
       }
     }
   } =>#t329;
@@ -2274,10 +2274,10 @@
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[1, 2, 3].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         core::int* i = :sync-for-iterator.{core::Iterator::current};
-        #t330.{core::Set::add}(i);
+        #t330.{core::Set::add}{Invariant}(i);
       }
     }
-    #t330.{core::Set::add}(null);
+    #t330.{core::Set::add}{Invariant}(null);
   } =>#t330;
   core::Map<core::String*, core::int*>* map110 = block {
     final core::Map<core::String*, core::int*>* #t331 = <core::String*, core::int*>{};
@@ -2285,10 +2285,10 @@
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[1, 2, 3].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         core::int* i = :sync-for-iterator.{core::Iterator::current};
-        #t331.{core::Map::[]=}("bar", i);
+        #t331.{core::Map::[]=}{Invariant}("bar", i);
       }
     }
-    #t331.{core::Map::[]=}("baz", null);
+    #t331.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t331;
   core::List<core::int*>* list120 = block {
     final core::List<core::int*>* #t332 = <core::int*>[];
@@ -2296,7 +2296,7 @@
       core::Iterator<dynamic>* :sync-for-iterator = (dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         dynamic i = :sync-for-iterator.{core::Iterator::current};
-        #t332.{core::List::add}(i as{TypeError,ForDynamic} core::int*);
+        #t332.{core::List::add}{Invariant}(i as{TypeError,ForDynamic} core::int*);
       }
     }
   } =>#t332;
@@ -2306,10 +2306,10 @@
       core::Iterator<dynamic>* :sync-for-iterator = (dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         dynamic i = :sync-for-iterator.{core::Iterator::current};
-        #t333.{core::Set::add}(i as{TypeError,ForDynamic} core::int*);
+        #t333.{core::Set::add}{Invariant}(i as{TypeError,ForDynamic} core::int*);
       }
     }
-    #t333.{core::Set::add}(null);
+    #t333.{core::Set::add}{Invariant}(null);
   } =>#t333;
   core::Map<core::String*, core::int*>* map120 = block {
     final core::Map<core::String*, core::int*>* #t334 = <core::String*, core::int*>{};
@@ -2317,25 +2317,25 @@
       core::Iterator<dynamic>* :sync-for-iterator = (dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         dynamic i = :sync-for-iterator.{core::Iterator::current};
-        #t334.{core::Map::[]=}("bar", i as{TypeError,ForDynamic} core::int*);
+        #t334.{core::Map::[]=}{Invariant}("bar", i as{TypeError,ForDynamic} core::int*);
       }
     }
-    #t334.{core::Map::[]=}("baz", null);
+    #t334.{core::Map::[]=}{Invariant}("baz", null);
   } =>#t334;
   core::List<core::int*>* list130 = block {
     final core::List<core::int*>* #t335 = <core::int*>[];
     for (core::int* i = 1; i.{core::num::<}(2); i = i.{core::num::+}(1))
-      #t335.{core::List::add}(i);
+      #t335.{core::List::add}{Invariant}(i);
   } =>#t335;
   core::Set<core::int*>* set130 = block {
     final core::Set<core::int*>* #t336 = new col::_CompactLinkedHashSet::•<core::int*>();
     for (core::int* i = 1; i.{core::num::<}(2); i = i.{core::num::+}(1))
-      #t336.{core::Set::add}(i);
+      #t336.{core::Set::add}{Invariant}(i);
   } =>#t336;
   core::Map<core::int*, core::int*>* map130 = block {
     final core::Map<core::int*, core::int*>* #t337 = <core::int*, core::int*>{};
     for (core::int* i = 1; i.{core::num::<}(2); i = i.{core::num::+}(1))
-      #t337.{core::Map::[]=}(i, i);
+      #t337.{core::Map::[]=}{Invariant}(i, i);
   } =>#t337;
 }
 static method testForElementErrors(core::Map<core::int*, core::int*>* map, core::List<core::int*>* list) → dynamic /* originally async */ {
@@ -2358,27 +2358,27 @@
         block {
           final core::List<core::int*>* #t338 = <core::int*>[];
           for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-            #t338.{core::List::add}(let final<BottomType> #t339 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:212:45: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+            #t338.{core::List::add}{Invariant}(let final<BottomType> #t339 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:212:45: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int>[for (int i = 0; oracle(\"foo\"); i++) \"bar\"];
                                             ^" in "bar" as{TypeError} core::int*);
         } =>#t338;
         block {
           final core::Set<core::int*>* #t340 = new col::_CompactLinkedHashSet::•<core::int*>();
           for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-            #t340.{core::Set::add}(let final<BottomType> #t341 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:213:45: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+            #t340.{core::Set::add}{Invariant}(let final<BottomType> #t341 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:213:45: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int>{for (int i = 0; oracle(\"foo\"); i++) \"bar\", null};
                                             ^" in "bar" as{TypeError} core::int*);
-          #t340.{core::Set::add}(null);
+          #t340.{core::Set::add}{Invariant}(null);
         } =>#t340;
         block {
           final core::Map<core::int*, core::int*>* #t342 = <core::int*, core::int*>{};
           for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-            #t342.{core::Map::[]=}(let final<BottomType> #t343 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:214:50: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+            #t342.{core::Map::[]=}{Invariant}(let final<BottomType> #t343 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:214:50: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int, int>{for (int i = 0; oracle(\"foo\"); i++) \"bar\": \"bar\", \"baz\": null};
                                                  ^" in "bar" as{TypeError} core::int*, let final<BottomType> #t344 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:214:57: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int, int>{for (int i = 0; oracle(\"foo\"); i++) \"bar\": \"bar\", \"baz\": null};
                                                         ^" in "bar" as{TypeError} core::int*);
-          #t342.{core::Map::[]=}(let final<BottomType> #t345 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:214:64: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+          #t342.{core::Map::[]=}{Invariant}(let final<BottomType> #t345 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:214:64: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int, int>{for (int i = 0; oracle(\"foo\"); i++) \"bar\": \"bar\", \"baz\": null};
                                                                ^" in "baz" as{TypeError} core::int*, null);
         } =>#t342;
@@ -2390,7 +2390,7 @@
                                                 ^" in "bar" as{TypeError} core::int*].{core::Iterable::iterator};
             for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
               final core::int* #t348 = :sync-for-iterator.{core::Iterator::current};
-              #t346.{core::List::add}(#t348);
+              #t346.{core::List::add}{Invariant}(#t348);
             }
           }
         } =>#t346;
@@ -2402,10 +2402,10 @@
                                                 ^" in "bar" as{TypeError} core::int*].{core::Iterable::iterator};
             for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
               final core::int* #t351 = :sync-for-iterator.{core::Iterator::current};
-              #t349.{core::Set::add}(#t351);
+              #t349.{core::Set::add}{Invariant}(#t351);
             }
           }
-          #t349.{core::Set::add}(null);
+          #t349.{core::Set::add}{Invariant}(null);
         } =>#t349;
         block {
           final core::Map<core::int*, core::int*>* #t352 = <core::int*, core::int*>{};
@@ -2417,17 +2417,17 @@
                                                             ^" in "bar" as{TypeError} core::int*}.{core::Map::entries}.{core::Iterable::iterator};
             for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
               final core::MapEntry<core::int*, core::int*>* #t355 = :sync-for-iterator.{core::Iterator::current};
-              #t352.{core::Map::[]=}(#t355.{core::MapEntry::key}, #t355.{core::MapEntry::value});
+              #t352.{core::Map::[]=}{Invariant}(#t355.{core::MapEntry::key}, #t355.{core::MapEntry::value});
             }
           }
-          #t352.{core::Map::[]=}(let final<BottomType> #t356 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:217:69: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
+          #t352.{core::Map::[]=}{Invariant}(let final<BottomType> #t356 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:217:69: Error: A value of type 'String' can't be assigned to a variable of type 'int'.
   <int, int>{for (int i = 0; oracle(\"foo\"); i++) ...{\"bar\": \"bar\"}, \"baz\": null};
                                                                     ^" in "baz" as{TypeError} core::int*, null);
         } =>#t352;
         block {
           final core::List<core::int*>* #t357 = <core::int*>[];
           for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-            #t357.{core::List::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:218:48: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+            #t357.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:218:48: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>[for (int i = 0; oracle(\"foo\"); i++) ...map];
                                                ^");
@@ -2435,11 +2435,11 @@
         block {
           final core::Set<core::int*>* #t358 = new col::_CompactLinkedHashSet::•<core::int*>();
           for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
-            #t358.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:219:48: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+            #t358.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:219:48: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>{for (int i = 0; oracle(\"foo\"); i++) ...map, null};
                                                ^");
-          #t358.{core::Set::add}(null);
+          #t358.{core::Set::add}{Invariant}(null);
         } =>#t358;
         <core::int*, core::int*>{invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:220:53: Error: Unexpected type 'List<int>' of a map spread entry.  Expected 'dynamic' or a Map.
  - 'List' is from 'dart:core'.
@@ -2452,11 +2452,11 @@
           final core::List<core::String*>* #t359 = <core::String*>[];
           for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
             if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-              #t359.{core::List::add}(let final<BottomType> #t360 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:221:62: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+              #t359.{core::List::add}{Invariant}(let final<BottomType> #t360 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:221:62: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   <String>[for (int i = 0; oracle(\"foo\"); i++) if (oracle()) 42 else 3.14];
                                                              ^" in 42 as{TypeError} core::String*);
             else
-              #t359.{core::List::add}(let final<BottomType> #t361 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:221:70: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
+              #t359.{core::List::add}{Invariant}(let final<BottomType> #t361 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:221:70: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
   <String>[for (int i = 0; oracle(\"foo\"); i++) if (oracle()) 42 else 3.14];
                                                                      ^" in 3.14 as{TypeError} core::String*);
         } =>#t359;
@@ -2464,50 +2464,50 @@
           final core::Set<core::String*>* #t362 = new col::_CompactLinkedHashSet::•<core::String*>();
           for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
             if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-              #t362.{core::Set::add}(let final<BottomType> #t363 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:222:62: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+              #t362.{core::Set::add}{Invariant}(let final<BottomType> #t363 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:222:62: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   <String>{for (int i = 0; oracle(\"foo\"); i++) if (oracle()) 42 else 3.14, null};
                                                              ^" in 42 as{TypeError} core::String*);
             else
-              #t362.{core::Set::add}(let final<BottomType> #t364 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:222:70: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
+              #t362.{core::Set::add}{Invariant}(let final<BottomType> #t364 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:222:70: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
   <String>{for (int i = 0; oracle(\"foo\"); i++) if (oracle()) 42 else 3.14, null};
                                                                      ^" in 3.14 as{TypeError} core::String*);
-          #t362.{core::Set::add}(null);
+          #t362.{core::Set::add}{Invariant}(null);
         } =>#t362;
         block {
           final core::Map<core::String*, core::String*>* #t365 = <core::String*, core::String*>{};
           for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
             if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-              #t365.{core::Map::[]=}("bar", let final<BottomType> #t366 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:223:77: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
+              #t365.{core::Map::[]=}{Invariant}("bar", let final<BottomType> #t366 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:223:77: Error: A value of type 'int' can't be assigned to a variable of type 'String'.
   <String, String>{for (int i = 0; oracle(\"foo\"); i++) if (oracle()) \"bar\": 42 else \"bar\": 3.14, \"baz\": null};
                                                                             ^" in 42 as{TypeError} core::String*);
             else
-              #t365.{core::Map::[]=}("bar", let final<BottomType> #t367 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:223:92: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
+              #t365.{core::Map::[]=}{Invariant}("bar", let final<BottomType> #t367 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:223:92: Error: A value of type 'double' can't be assigned to a variable of type 'String'.
   <String, String>{for (int i = 0; oracle(\"foo\"); i++) if (oracle()) \"bar\": 42 else \"bar\": 3.14, \"baz\": null};
                                                                                            ^" in 3.14 as{TypeError} core::String*);
-          #t365.{core::Map::[]=}("baz", null);
+          #t365.{core::Map::[]=}{Invariant}("baz", null);
         } =>#t365;
         block {
           final core::List<core::int*>* #t368 = <core::int*>[];
           for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
             if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-              #t368.{core::List::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:224:62: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+              #t368.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:224:62: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>[for (int i = 0; oracle(\"foo\"); i++) if (oracle()) ...map else 42];
                                                              ^");
             else
-              #t368.{core::List::add}(42);
+              #t368.{core::List::add}{Invariant}(42);
         } =>#t368;
         block {
           final core::Set<core::int*>* #t369 = new col::_CompactLinkedHashSet::•<core::int*>();
           for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
             if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-              #t369.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:225:62: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+              #t369.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:225:62: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>{for (int i = 0; oracle(\"foo\"); i++) if (oracle()) ...map else 42, null};
                                                              ^");
             else
-              #t369.{core::Set::add}(42);
-          #t369.{core::Set::add}(null);
+              #t369.{core::Set::add}{Invariant}(42);
+          #t369.{core::Set::add}{Invariant}(null);
         } =>#t369;
         <core::String*, core::int*>{invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:226:70: Error: Unexpected type 'List<int>' of a map spread entry.  Expected 'dynamic' or a Map.
  - 'List' is from 'dart:core'.
@@ -2520,9 +2520,9 @@
           final core::List<core::int*>* #t370 = <core::int*>[];
           for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
             if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-              #t370.{core::List::add}(42);
+              #t370.{core::List::add}{Invariant}(42);
             else
-              #t370.{core::List::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:227:70: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+              #t370.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:227:70: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>[for (int i = 0; oracle(\"foo\"); i++) if (oracle()) 42 else ...map];
                                                                      ^");
@@ -2531,13 +2531,13 @@
           final core::Set<core::int*>* #t371 = new col::_CompactLinkedHashSet::•<core::int*>();
           for (core::int* i = 0; self::oracle<core::String*>("foo") as{TypeError,ForDynamic} core::bool*; i = i.{core::num::+}(1))
             if(self::oracle<dynamic>() as{TypeError,ForDynamic} core::bool*)
-              #t371.{core::Set::add}(42);
+              #t371.{core::Set::add}{Invariant}(42);
             else
-              #t371.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:228:70: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
+              #t371.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:228:70: Error: Unexpected type 'Map<int, int>' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
   <int>{for (int i = 0; oracle(\"foo\"); i++) if (oracle()) 42 else ...map, null};
                                                                      ^");
-          #t371.{core::Set::add}(null);
+          #t371.{core::Set::add}{Invariant}(null);
         } =>#t371;
         <core::String*, core::int*>{invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:229:85: Error: Unexpected type 'List<int>' of a map spread entry.  Expected 'dynamic' or a Map.
  - 'List' is from 'dart:core'.
@@ -2557,7 +2557,7 @@
                 invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:232:14: Error: Can't assign to the final variable 'i'.
   <int>[for (i in <int>[1]) i];
              ^";
-                #t372.{core::List::add}(i);
+                #t372.{core::List::add}{Invariant}(i);
               }
             }
           }
@@ -2572,11 +2572,11 @@
                 invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:233:14: Error: Can't assign to the final variable 'i'.
   <int>{for (i in <int>[1]) i, null};
              ^";
-                #t374.{core::Set::add}(i);
+                #t374.{core::Set::add}{Invariant}(i);
               }
             }
           }
-          #t374.{core::Set::add}(null);
+          #t374.{core::Set::add}{Invariant}(null);
         } =>#t374;
         block {
           final core::Map<core::String*, core::int*>* #t376 = <core::String*, core::int*>{};
@@ -2588,11 +2588,11 @@
                 invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:234:21: Error: Can't assign to the final variable 'i'.
 \t<String, int>{for (i in <int>[1]) \"bar\": i, \"baz\": null};
 \t                   ^";
-                #t376.{core::Map::[]=}("bar", i);
+                #t376.{core::Map::[]=}{Invariant}("bar", i);
               }
             }
           }
-          #t376.{core::Map::[]=}("baz", null);
+          #t376.{core::Map::[]=}{Invariant}("baz", null);
         } =>#t376;
         core::List<dynamic>* list10 = block {
           final core::List<dynamic>* #t378 = <dynamic>[];
@@ -2603,7 +2603,7 @@
                               ^" in "not iterable" as{TypeError} core::Iterable<dynamic>*).{core::Iterable::iterator};
             for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
               dynamic i = :sync-for-iterator.{core::Iterator::current};
-              #t378.{core::List::add}(i);
+              #t378.{core::List::add}{Invariant}(i);
             }
           }
         } =>#t378;
@@ -2616,10 +2616,10 @@
                              ^" in "not iterable" as{TypeError} core::Iterable<dynamic>*).{core::Iterable::iterator};
             for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
               dynamic i = :sync-for-iterator.{core::Iterator::current};
-              #t380.{core::Set::add}(i);
+              #t380.{core::Set::add}{Invariant}(i);
             }
           }
-          #t380.{core::Set::add}(null);
+          #t380.{core::Set::add}{Invariant}(null);
         } =>#t380;
         core::Map<core::String*, dynamic>* map10 = block {
           final core::Map<core::String*, dynamic>* #t382 = <core::String*, dynamic>{};
@@ -2630,10 +2630,10 @@
                              ^" in "not iterable" as{TypeError} core::Iterable<dynamic>*).{core::Iterable::iterator};
             for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
               dynamic i = :sync-for-iterator.{core::Iterator::current};
-              #t382.{core::Map::[]=}("bar", i);
+              #t382.{core::Map::[]=}{Invariant}("bar", i);
             }
           }
-          #t382.{core::Map::[]=}("baz", null);
+          #t382.{core::Map::[]=}{Invariant}("baz", null);
         } =>#t382;
         core::List<core::int*>* list20 = block {
           final core::List<core::int*>* #t384 = <core::int*>[];
@@ -2645,7 +2645,7 @@
                                       ^" in "int" as{TypeError} core::int*].{core::Iterable::iterator};
             for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
               core::int* i = :sync-for-iterator.{core::Iterator::current};
-              #t384.{core::List::add}(i);
+              #t384.{core::List::add}{Invariant}(i);
             }
           }
         } =>#t384;
@@ -2659,10 +2659,10 @@
                                      ^" in "int" as{TypeError} core::int*].{core::Iterable::iterator};
             for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
               core::int* i = :sync-for-iterator.{core::Iterator::current};
-              #t387.{core::Set::add}(i);
+              #t387.{core::Set::add}{Invariant}(i);
             }
           }
-          #t387.{core::Set::add}(null);
+          #t387.{core::Set::add}{Invariant}(null);
         } =>#t387;
         core::Map<core::String*, core::int*>* map20 = block {
           final core::Map<core::String*, core::int*>* #t390 = <core::String*, core::int*>{};
@@ -2674,10 +2674,10 @@
                                      ^" in "int" as{TypeError} core::int*].{core::Iterable::iterator};
             for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
               core::int* i = :sync-for-iterator.{core::Iterator::current};
-              #t390.{core::Map::[]=}("bar", i);
+              #t390.{core::Map::[]=}{Invariant}("bar", i);
             }
           }
-          #t390.{core::Map::[]=}("baz", null);
+          #t390.{core::Map::[]=}{Invariant}("baz", null);
         } =>#t390;
         final core::List<dynamic>* #t393 = <dynamic>[];
         {
@@ -2693,7 +2693,7 @@
               [yield] let dynamic #t396 = asy::_awaitHelper(:for-iterator.{asy::_StreamIterator::moveNext}(), :async_op_then, :async_op_error, :async_op) in null;
               if(_in::unsafeCast<core::bool>(:result)) {
                 dynamic i = :for-iterator.{asy::_StreamIterator::current};
-                #t393.{core::List::add}(i);
+                #t393.{core::List::add}{Invariant}(i);
               }
               else
                 break #L2;
@@ -2719,7 +2719,7 @@
               [yield] let dynamic #t401 = asy::_awaitHelper(:for-iterator.{asy::_StreamIterator::moveNext}(), :async_op_then, :async_op_error, :async_op) in null;
               if(_in::unsafeCast<core::bool>(:result)) {
                 dynamic i = :for-iterator.{asy::_StreamIterator::current};
-                #t398.{core::Set::add}(i);
+                #t398.{core::Set::add}{Invariant}(i);
               }
               else
                 break #L3;
@@ -2731,7 +2731,7 @@
             }
         }
         core::Set<dynamic>* set30 = block {
-          #t398.{core::Set::add}(null);
+          #t398.{core::Set::add}{Invariant}(null);
         } =>#t398;
         final core::Map<core::String*, dynamic>* #t403 = <core::String*, dynamic>{};
         {
@@ -2747,7 +2747,7 @@
               [yield] let dynamic #t406 = asy::_awaitHelper(:for-iterator.{asy::_StreamIterator::moveNext}(), :async_op_then, :async_op_error, :async_op) in null;
               if(_in::unsafeCast<core::bool>(:result)) {
                 dynamic i = :for-iterator.{asy::_StreamIterator::current};
-                #t403.{core::Map::[]=}("bar", i);
+                #t403.{core::Map::[]=}{Invariant}("bar", i);
               }
               else
                 break #L4;
@@ -2759,7 +2759,7 @@
             }
         }
         core::Map<core::String*, dynamic>* map30 = block {
-          #t403.{core::Map::[]=}("baz", null);
+          #t403.{core::Map::[]=}{Invariant}("baz", null);
         } =>#t403;
         final core::List<core::int*>* #t408 = <core::int*>[];
         {
@@ -2776,7 +2776,7 @@
               [yield] let dynamic #t412 = asy::_awaitHelper(:for-iterator.{asy::_StreamIterator::moveNext}(), :async_op_then, :async_op_error, :async_op) in null;
               if(_in::unsafeCast<core::bool>(:result)) {
                 core::int* i = :for-iterator.{asy::_StreamIterator::current};
-                #t408.{core::List::add}(i);
+                #t408.{core::List::add}{Invariant}(i);
               }
               else
                 break #L5;
@@ -2803,7 +2803,7 @@
               [yield] let dynamic #t418 = asy::_awaitHelper(:for-iterator.{asy::_StreamIterator::moveNext}(), :async_op_then, :async_op_error, :async_op) in null;
               if(_in::unsafeCast<core::bool>(:result)) {
                 core::int* i = :for-iterator.{asy::_StreamIterator::current};
-                #t414.{core::Set::add}(i);
+                #t414.{core::Set::add}{Invariant}(i);
               }
               else
                 break #L6;
@@ -2815,7 +2815,7 @@
             }
         }
         core::Set<core::int*>* set40 = block {
-          #t414.{core::Set::add}(null);
+          #t414.{core::Set::add}{Invariant}(null);
         } =>#t414;
         final core::Map<core::String*, core::int*>* #t420 = <core::String*, core::int*>{};
         {
@@ -2832,7 +2832,7 @@
               [yield] let dynamic #t424 = asy::_awaitHelper(:for-iterator.{asy::_StreamIterator::moveNext}(), :async_op_then, :async_op_error, :async_op) in null;
               if(_in::unsafeCast<core::bool>(:result)) {
                 core::int* i = :for-iterator.{asy::_StreamIterator::current};
-                #t420.{core::Map::[]=}("bar", i);
+                #t420.{core::Map::[]=}{Invariant}("bar", i);
               }
               else
                 break #L7;
@@ -2844,47 +2844,47 @@
             }
         }
         core::Map<core::String*, core::int*>* map40 = block {
-          #t420.{core::Map::[]=}("baz", null);
+          #t420.{core::Map::[]=}{Invariant}("baz", null);
         } =>#t420;
         core::List<core::int*>* list50 = block {
           final core::List<core::int*>* #t426 = <core::int*>[];
           for (; ; )
-            #t426.{core::List::add}(42);
+            #t426.{core::List::add}{Invariant}(42);
         } =>#t426;
         core::Set<core::int*>* set50 = block {
           final core::Set<core::int*>* #t427 = new col::_CompactLinkedHashSet::•<core::int*>();
           for (; ; )
-            #t427.{core::Set::add}(42);
-          #t427.{core::Set::add}(null);
+            #t427.{core::Set::add}{Invariant}(42);
+          #t427.{core::Set::add}{Invariant}(null);
         } =>#t427;
         core::Map<core::String*, core::int*>* map50 = block {
           final core::Map<core::String*, core::int*>* #t428 = <core::String*, core::int*>{};
           for (; ; )
-            #t428.{core::Map::[]=}("bar", 42);
-          #t428.{core::Map::[]=}("baz", null);
+            #t428.{core::Map::[]=}{Invariant}("bar", 42);
+          #t428.{core::Map::[]=}{Invariant}("baz", null);
         } =>#t428;
         core::List<core::int*>* list60 = block {
           final core::List<core::int*>* #t429 = <core::int*>[];
           for (; let final<BottomType> #t430 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:251:24: Error: A value of type 'String' can't be assigned to a variable of type 'bool'.
   var list60 = [for (; \"not bool\";) 42];
                        ^" in "not bool" as{TypeError} core::bool*; )
-            #t429.{core::List::add}(42);
+            #t429.{core::List::add}{Invariant}(42);
         } =>#t429;
         core::Set<core::int*>* set60 = block {
           final core::Set<core::int*>* #t431 = new col::_CompactLinkedHashSet::•<core::int*>();
           for (; let final<BottomType> #t432 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:252:23: Error: A value of type 'String' can't be assigned to a variable of type 'bool'.
   var set60 = {for (; \"not bool\";) 42, null};
                       ^" in "not bool" as{TypeError} core::bool*; )
-            #t431.{core::Set::add}(42);
-          #t431.{core::Set::add}(null);
+            #t431.{core::Set::add}{Invariant}(42);
+          #t431.{core::Set::add}{Invariant}(null);
         } =>#t431;
         core::Map<core::String*, core::int*>* map60 = block {
           final core::Map<core::String*, core::int*>* #t433 = <core::String*, core::int*>{};
           for (; let final<BottomType> #t434 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/control_flow_collection_inference.dart:253:23: Error: A value of type 'String' can't be assigned to a variable of type 'bool'.
   var map60 = {for (; \"not bool\";) \"bar\": 42, \"baz\": null};
                       ^" in "not bool" as{TypeError} core::bool*; )
-            #t433.{core::Map::[]=}("bar", 42);
-          #t433.{core::Map::[]=}("baz", null);
+            #t433.{core::Map::[]=}{Invariant}("bar", 42);
+          #t433.{core::Map::[]=}{Invariant}("baz", null);
         } =>#t433;
       }
       asy::_completeOnAsyncReturn(:async_future, :return_value, :is_sync);
@@ -2904,34 +2904,34 @@
   block {
     final core::List<core::int*>* #t435 = <core::int*>[];
     await for (core::int* i in stream)
-      #t435.{core::List::add}(i);
+      #t435.{core::List::add}{Invariant}(i);
   } =>#t435;
   block {
     final core::Set<core::int*>* #t436 = new col::_CompactLinkedHashSet::•<core::int*>();
     await for (core::int* i in stream)
-      #t436.{core::Set::add}(i);
+      #t436.{core::Set::add}{Invariant}(i);
   } =>#t436;
   block {
     final core::Map<core::String*, core::int*>* #t437 = <core::String*, core::int*>{};
     await for (core::int* i in stream)
-      #t437.{core::Map::[]=}("bar", i);
+      #t437.{core::Map::[]=}{Invariant}("bar", i);
   } =>#t437;
 }
 static method testPromotion(self::A* a) → dynamic {
   core::List<core::int*>* list10 = block {
     final core::List<core::int*>* #t438 = <core::int*>[];
     if(a is self::B*)
-      #t438.{core::List::add}(a{self::B*}.{self::B::foo});
+      #t438.{core::List::add}{Invariant}(a{self::B*}.{self::B::foo});
   } =>#t438;
   core::Set<core::int*>* set10 = block {
     final core::Set<core::int*>* #t439 = new col::_CompactLinkedHashSet::•<core::int*>();
     if(a is self::B*)
-      #t439.{core::Set::add}(a{self::B*}.{self::B::foo});
+      #t439.{core::Set::add}{Invariant}(a{self::B*}.{self::B::foo});
   } =>#t439;
   core::Map<core::int*, core::int*>* map10 = block {
     final core::Map<core::int*, core::int*>* #t440 = <core::int*, core::int*>{};
     if(a is self::B*)
-      #t440.{core::Map::[]=}(a{self::B*}.{self::B::foo}, a{self::B*}.{self::B::foo});
+      #t440.{core::Map::[]=}{Invariant}(a{self::B*}.{self::B::foo}, a{self::B*}.{self::B::foo});
   } =>#t440;
 }
 static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/general_nnbd_opt_out/if_null_in_set_literal.dart.weak.expect b/pkg/front_end/testcases/general_nnbd_opt_out/if_null_in_set_literal.dart.weak.expect
index cf3316a..bbc6109 100644
--- a/pkg/front_end/testcases/general_nnbd_opt_out/if_null_in_set_literal.dart.weak.expect
+++ b/pkg/front_end/testcases/general_nnbd_opt_out/if_null_in_set_literal.dart.weak.expect
@@ -8,6 +8,6 @@
   core::Object* b;
   return block {
     final core::Set<core::Object*>* #t1 = col::LinkedHashSet::•<core::Object*>();
-    #t1.{core::Set::add}(let final core::Object* #t2 = a in #t2.{core::Object::==}(null) ?{core::Object*} b : #t2);
+    #t1.{core::Set::add}{Invariant}(let final core::Object* #t2 = a in #t2.{core::Object::==}(null) ?{core::Object*} b : #t2);
   } =>#t1;
 }
diff --git a/pkg/front_end/testcases/general_nnbd_opt_out/if_null_in_set_literal.dart.weak.transformed.expect b/pkg/front_end/testcases/general_nnbd_opt_out/if_null_in_set_literal.dart.weak.transformed.expect
index d304f46..637e41b 100644
--- a/pkg/front_end/testcases/general_nnbd_opt_out/if_null_in_set_literal.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/general_nnbd_opt_out/if_null_in_set_literal.dart.weak.transformed.expect
@@ -8,6 +8,6 @@
   core::Object* b;
   return block {
     final core::Set<core::Object*>* #t1 = new col::_CompactLinkedHashSet::•<core::Object*>();
-    #t1.{core::Set::add}(let final core::Object* #t2 = a in #t2.{core::Object::==}(null) ?{core::Object*} b : #t2);
+    #t1.{core::Set::add}{Invariant}(let final core::Object* #t2 = a in #t2.{core::Object::==}(null) ?{core::Object*} b : #t2);
   } =>#t1;
 }
diff --git a/pkg/front_end/testcases/general_nnbd_opt_out/issue37027.dart.weak.expect b/pkg/front_end/testcases/general_nnbd_opt_out/issue37027.dart.weak.expect
index 09fd889..d66702b 100644
--- a/pkg/front_end/testcases/general_nnbd_opt_out/issue37027.dart.weak.expect
+++ b/pkg/front_end/testcases/general_nnbd_opt_out/issue37027.dart.weak.expect
@@ -10,7 +10,7 @@
       final core::Set<core::int*>* #t1 = col::LinkedHashSet::•<core::int*>();
       for (core::int* e in ell)
         if(e.{core::int::isOdd})
-          #t1.{core::Set::add}(2.{core::num::*}(e));
+          #t1.{core::Set::add}{Invariant}(2.{core::num::*}(e));
     } =>#t1, super core::Object::•()
     ;
   abstract member-signature get _identityHashCode() → core::int*; -> core::Object::_identityHashCode
diff --git a/pkg/front_end/testcases/general_nnbd_opt_out/issue37027.dart.weak.transformed.expect b/pkg/front_end/testcases/general_nnbd_opt_out/issue37027.dart.weak.transformed.expect
index bc72e7f..fa88301 100644
--- a/pkg/front_end/testcases/general_nnbd_opt_out/issue37027.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/general_nnbd_opt_out/issue37027.dart.weak.transformed.expect
@@ -13,7 +13,7 @@
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           core::int* e = :sync-for-iterator.{core::Iterator::current};
           if(e.{core::int::isOdd})
-            #t1.{core::Set::add}(2.{core::num::*}(e));
+            #t1.{core::Set::add}{Invariant}(2.{core::num::*}(e));
         }
       }
     } =>#t1, super core::Object::•()
diff --git a/pkg/front_end/testcases/general_nnbd_opt_out/null_aware_spread.dart.weak.expect b/pkg/front_end/testcases/general_nnbd_opt_out/null_aware_spread.dart.weak.expect
index b724b3a..bd5bf0d 100644
--- a/pkg/front_end/testcases/general_nnbd_opt_out/null_aware_spread.dart.weak.expect
+++ b/pkg/front_end/testcases/general_nnbd_opt_out/null_aware_spread.dart.weak.expect
@@ -6,31 +6,31 @@
 static method nullAwareListSpread(core::List<core::String*>* list) → dynamic {
   list = block {
     final core::List<core::String*>* #t1 = <core::String*>[];
-    #t1.{core::List::add}("foo");
+    #t1.{core::List::add}{Invariant}("foo");
     final core::Iterable<core::String*>* #t2 = list;
     if(!#t2.{core::Object::==}(null))
       for (final core::String* #t3 in #t2)
-        #t1.{core::List::add}(#t3);
+        #t1.{core::List::add}{Invariant}(#t3);
   } =>#t1;
 }
 static method nullAwareSetSpread(core::Set<core::String*>* set) → dynamic {
   set = block {
     final core::Set<core::String*>* #t4 = col::LinkedHashSet::•<core::String*>();
-    #t4.{core::Set::add}("foo");
+    #t4.{core::Set::add}{Invariant}("foo");
     final core::Iterable<core::String*>* #t5 = set;
     if(!#t5.{core::Object::==}(null))
       for (final core::String* #t6 in #t5)
-        #t4.{core::Set::add}(#t6);
+        #t4.{core::Set::add}{Invariant}(#t6);
   } =>#t4;
 }
 static method nullAwareMapSpread(core::Map<core::int*, core::String*>* map) → dynamic {
   map = block {
     final core::Map<core::int*, core::String*>* #t7 = <core::int*, core::String*>{};
-    #t7.{core::Map::[]=}(0, "foo");
+    #t7.{core::Map::[]=}{Invariant}(0, "foo");
     final core::Map<core::int*, core::String*>* #t8 = map;
     if(!#t8.{core::Object::==}(null))
       for (final core::MapEntry<core::int*, core::String*>* #t9 in #t8.{core::Map::entries})
-        #t7.{core::Map::[]=}(#t9.{core::MapEntry::key}, #t9.{core::MapEntry::value});
+        #t7.{core::Map::[]=}{Invariant}(#t9.{core::MapEntry::key}, #t9.{core::MapEntry::value});
   } =>#t7;
 }
 static method main() → dynamic {
diff --git a/pkg/front_end/testcases/general_nnbd_opt_out/null_aware_spread.dart.weak.transformed.expect b/pkg/front_end/testcases/general_nnbd_opt_out/null_aware_spread.dart.weak.transformed.expect
index 9ff4788..67a6d44 100644
--- a/pkg/front_end/testcases/general_nnbd_opt_out/null_aware_spread.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/general_nnbd_opt_out/null_aware_spread.dart.weak.transformed.expect
@@ -6,13 +6,13 @@
 static method nullAwareListSpread(core::List<core::String*>* list) → dynamic {
   list = block {
     final core::List<core::String*>* #t1 = <core::String*>[];
-    #t1.{core::List::add}("foo");
+    #t1.{core::List::add}{Invariant}("foo");
     final core::Iterable<core::String*>* #t2 = list;
     if(!#t2.{core::Object::==}(null)) {
       core::Iterator<core::String*>* :sync-for-iterator = #t2.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::String* #t3 = :sync-for-iterator.{core::Iterator::current};
-        #t1.{core::List::add}(#t3);
+        #t1.{core::List::add}{Invariant}(#t3);
       }
     }
   } =>#t1;
@@ -20,13 +20,13 @@
 static method nullAwareSetSpread(core::Set<core::String*>* set) → dynamic {
   set = block {
     final core::Set<core::String*>* #t4 = new col::_CompactLinkedHashSet::•<core::String*>();
-    #t4.{core::Set::add}("foo");
+    #t4.{core::Set::add}{Invariant}("foo");
     final core::Iterable<core::String*>* #t5 = set;
     if(!#t5.{core::Object::==}(null)) {
       core::Iterator<core::String*>* :sync-for-iterator = #t5.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::String* #t6 = :sync-for-iterator.{core::Iterator::current};
-        #t4.{core::Set::add}(#t6);
+        #t4.{core::Set::add}{Invariant}(#t6);
       }
     }
   } =>#t4;
@@ -34,13 +34,13 @@
 static method nullAwareMapSpread(core::Map<core::int*, core::String*>* map) → dynamic {
   map = block {
     final core::Map<core::int*, core::String*>* #t7 = <core::int*, core::String*>{};
-    #t7.{core::Map::[]=}(0, "foo");
+    #t7.{core::Map::[]=}{Invariant}(0, "foo");
     final core::Map<core::int*, core::String*>* #t8 = map;
     if(!#t8.{core::Object::==}(null)) {
       core::Iterator<core::MapEntry<core::int*, core::String*>>* :sync-for-iterator = #t8.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::int*, core::String*>* #t9 = :sync-for-iterator.{core::Iterator::current};
-        #t7.{core::Map::[]=}(#t9.{core::MapEntry::key}, #t9.{core::MapEntry::value});
+        #t7.{core::Map::[]=}{Invariant}(#t9.{core::MapEntry::key}, #t9.{core::MapEntry::value});
       }
     }
   } =>#t7;
diff --git a/pkg/front_end/testcases/general_nnbd_opt_out/spread_collection.dart.weak.expect b/pkg/front_end/testcases/general_nnbd_opt_out/spread_collection.dart.weak.expect
index b24bbda..c862e55 100644
--- a/pkg/front_end/testcases/general_nnbd_opt_out/spread_collection.dart.weak.expect
+++ b/pkg/front_end/testcases/general_nnbd_opt_out/spread_collection.dart.weak.expect
@@ -14,33 +14,33 @@
 static method main() → dynamic {
   final core::List<core::int*>* aList = block {
     final core::List<core::int*>* #t1 = <core::int*>[];
-    #t1.{core::List::add}(1);
+    #t1.{core::List::add}{Invariant}(1);
     for (final core::int* #t2 in <core::int*>[2])
-      #t1.{core::List::add}(#t2);
+      #t1.{core::List::add}{Invariant}(#t2);
     final core::Iterable<core::int*>* #t3 = <core::int*>[3];
     if(!#t3.{core::Object::==}(null))
       for (final core::int* #t4 in #t3)
-        #t1.{core::List::add}(#t4);
+        #t1.{core::List::add}{Invariant}(#t4);
   } =>#t1;
   final core::Map<core::int*, core::int*>* aMap = block {
     final core::Map<core::int*, core::int*>* #t5 = <core::int*, core::int*>{};
-    #t5.{core::Map::[]=}(1, 1);
+    #t5.{core::Map::[]=}{Invariant}(1, 1);
     for (final core::MapEntry<core::int*, core::int*>* #t6 in <core::int*, core::int*>{2: 2}.{core::Map::entries})
-      #t5.{core::Map::[]=}(#t6.{core::MapEntry::key}, #t6.{core::MapEntry::value});
+      #t5.{core::Map::[]=}{Invariant}(#t6.{core::MapEntry::key}, #t6.{core::MapEntry::value});
     final core::Map<core::int*, core::int*>* #t7 = <core::int*, core::int*>{3: 3};
     if(!#t7.{core::Object::==}(null))
       for (final core::MapEntry<core::int*, core::int*>* #t8 in #t7.{core::Map::entries})
-        #t5.{core::Map::[]=}(#t8.{core::MapEntry::key}, #t8.{core::MapEntry::value});
+        #t5.{core::Map::[]=}{Invariant}(#t8.{core::MapEntry::key}, #t8.{core::MapEntry::value});
   } =>#t5;
   final core::Set<core::int*>* aSet = block {
     final core::Set<core::int*>* #t9 = col::LinkedHashSet::•<core::int*>();
-    #t9.{core::Set::add}(1);
+    #t9.{core::Set::add}{Invariant}(1);
     for (final core::int* #t10 in <core::int*>[2])
-      #t9.{core::Set::add}(#t10);
+      #t9.{core::Set::add}{Invariant}(#t10);
     final core::Iterable<core::int*>* #t11 = <core::int*>[3];
     if(!#t11.{core::Object::==}(null))
       for (final core::int* #t12 in #t11)
-        #t9.{core::Set::add}(#t12);
+        #t9.{core::Set::add}{Invariant}(#t12);
   } =>#t9;
   final dynamic aSetOrMap = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection.dart:23:21: Error: Not enough type information to disambiguate between literal set and literal map.
 Try providing type arguments for the literal explicitly to disambiguate it.
diff --git a/pkg/front_end/testcases/general_nnbd_opt_out/spread_collection.dart.weak.transformed.expect b/pkg/front_end/testcases/general_nnbd_opt_out/spread_collection.dart.weak.transformed.expect
index f06f6bc..791309b 100644
--- a/pkg/front_end/testcases/general_nnbd_opt_out/spread_collection.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/general_nnbd_opt_out/spread_collection.dart.weak.transformed.expect
@@ -14,12 +14,12 @@
 static method main() → dynamic {
   final core::List<core::int*>* aList = block {
     final core::List<core::int*>* #t1 = <core::int*>[];
-    #t1.{core::List::add}(1);
+    #t1.{core::List::add}{Invariant}(1);
     {
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[2].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t2 = :sync-for-iterator.{core::Iterator::current};
-        #t1.{core::List::add}(#t2);
+        #t1.{core::List::add}{Invariant}(#t2);
       }
     }
     final core::Iterable<core::int*>* #t3 = <core::int*>[3];
@@ -27,18 +27,18 @@
       core::Iterator<core::int*>* :sync-for-iterator = #t3.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t4 = :sync-for-iterator.{core::Iterator::current};
-        #t1.{core::List::add}(#t4);
+        #t1.{core::List::add}{Invariant}(#t4);
       }
     }
   } =>#t1;
   final core::Map<core::int*, core::int*>* aMap = block {
     final core::Map<core::int*, core::int*>* #t5 = <core::int*, core::int*>{};
-    #t5.{core::Map::[]=}(1, 1);
+    #t5.{core::Map::[]=}{Invariant}(1, 1);
     {
       core::Iterator<core::MapEntry<core::int*, core::int*>>* :sync-for-iterator = <core::int*, core::int*>{2: 2}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::int*, core::int*>* #t6 = :sync-for-iterator.{core::Iterator::current};
-        #t5.{core::Map::[]=}(#t6.{core::MapEntry::key}, #t6.{core::MapEntry::value});
+        #t5.{core::Map::[]=}{Invariant}(#t6.{core::MapEntry::key}, #t6.{core::MapEntry::value});
       }
     }
     final core::Map<core::int*, core::int*>* #t7 = <core::int*, core::int*>{3: 3};
@@ -46,18 +46,18 @@
       core::Iterator<core::MapEntry<core::int*, core::int*>>* :sync-for-iterator = #t7.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::int*, core::int*>* #t8 = :sync-for-iterator.{core::Iterator::current};
-        #t5.{core::Map::[]=}(#t8.{core::MapEntry::key}, #t8.{core::MapEntry::value});
+        #t5.{core::Map::[]=}{Invariant}(#t8.{core::MapEntry::key}, #t8.{core::MapEntry::value});
       }
     }
   } =>#t5;
   final core::Set<core::int*>* aSet = block {
     final core::Set<core::int*>* #t9 = new col::_CompactLinkedHashSet::•<core::int*>();
-    #t9.{core::Set::add}(1);
+    #t9.{core::Set::add}{Invariant}(1);
     {
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[2].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t10 = :sync-for-iterator.{core::Iterator::current};
-        #t9.{core::Set::add}(#t10);
+        #t9.{core::Set::add}{Invariant}(#t10);
       }
     }
     final core::Iterable<core::int*>* #t11 = <core::int*>[3];
@@ -65,7 +65,7 @@
       core::Iterator<core::int*>* :sync-for-iterator = #t11.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t12 = :sync-for-iterator.{core::Iterator::current};
-        #t9.{core::Set::add}(#t12);
+        #t9.{core::Set::add}{Invariant}(#t12);
       }
     }
   } =>#t9;
diff --git a/pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart.weak.expect b/pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart.weak.expect
index 51ab54a..6d91849 100644
--- a/pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart.weak.expect
+++ b/pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart.weak.expect
@@ -112,68 +112,68 @@
   core::List<dynamic>* lhs10 = block {
     final core::List<dynamic>* #t1 = <dynamic>[];
     for (final dynamic #t2 in <dynamic>[])
-      #t1.{core::List::add}(#t2);
+      #t1.{core::List::add}{Invariant}(#t2);
   } =>#t1;
   core::Set<dynamic>* set10 = block {
     final core::Set<dynamic>* #t3 = col::LinkedHashSet::•<dynamic>();
     for (final dynamic #t4 in <dynamic>[])
-      #t3.{core::Set::add}(#t4);
+      #t3.{core::Set::add}{Invariant}(#t4);
   } =>#t3;
   core::Map<dynamic, dynamic>* map10 = block {
     final core::Map<dynamic, dynamic>* #t5 = <dynamic, dynamic>{};
     for (final core::MapEntry<dynamic, dynamic>* #t6 in <dynamic, dynamic>{}.{core::Map::entries})
-      #t5.{core::Map::[]=}(#t6.{core::MapEntry::key}, #t6.{core::MapEntry::value});
+      #t5.{core::Map::[]=}{Invariant}(#t6.{core::MapEntry::key}, #t6.{core::MapEntry::value});
   } =>#t5;
   core::Map<dynamic, dynamic>* map10ambiguous = block {
     final core::Map<dynamic, dynamic>* #t7 = <dynamic, dynamic>{};
     for (final core::MapEntry<dynamic, dynamic>* #t8 in <dynamic, dynamic>{}.{core::Map::entries})
-      #t7.{core::Map::[]=}(#t8.{core::MapEntry::key}, #t8.{core::MapEntry::value});
+      #t7.{core::Map::[]=}{Invariant}(#t8.{core::MapEntry::key}, #t8.{core::MapEntry::value});
   } =>#t7;
   core::List<core::int*>* lhs20 = block {
     final core::List<core::int*>* #t9 = <core::int*>[];
     for (final core::int* #t10 in spread)
-      #t9.{core::List::add}(#t10);
+      #t9.{core::List::add}{Invariant}(#t10);
   } =>#t9;
   core::Set<core::int*>* set20 = block {
     final core::Set<core::int*>* #t11 = col::LinkedHashSet::•<core::int*>();
     for (final core::int* #t12 in spread)
-      #t11.{core::Set::add}(#t12);
-    #t11.{core::Set::add}(42);
+      #t11.{core::Set::add}{Invariant}(#t12);
+    #t11.{core::Set::add}{Invariant}(42);
   } =>#t11;
   core::Set<core::int*>* set20ambiguous = block {
     final core::Set<core::int*>* #t13 = col::LinkedHashSet::•<core::int*>();
     for (final dynamic #t14 in spread) {
       final core::int* #t15 = #t14 as{TypeError} core::int*;
-      #t13.{core::Set::add}(#t15);
+      #t13.{core::Set::add}{Invariant}(#t15);
     }
   } =>#t13;
   core::Map<core::String*, core::int*>* map20 = block {
     final core::Map<core::String*, core::int*>* #t16 = <core::String*, core::int*>{};
     for (final core::MapEntry<core::String*, core::int*>* #t17 in mapSpread.{core::Map::entries})
-      #t16.{core::Map::[]=}(#t17.{core::MapEntry::key}, #t17.{core::MapEntry::value});
-    #t16.{core::Map::[]=}("baz", 42);
+      #t16.{core::Map::[]=}{Invariant}(#t17.{core::MapEntry::key}, #t17.{core::MapEntry::value});
+    #t16.{core::Map::[]=}{Invariant}("baz", 42);
   } =>#t16;
   core::Map<core::String*, core::int*>* map20ambiguous = block {
     final core::Map<core::String*, core::int*>* #t18 = <core::String*, core::int*>{};
     for (final core::MapEntry<core::String*, core::int*>* #t19 in mapSpread.{core::Map::entries})
-      #t18.{core::Map::[]=}(#t19.{core::MapEntry::key}, #t19.{core::MapEntry::value});
+      #t18.{core::Map::[]=}{Invariant}(#t19.{core::MapEntry::key}, #t19.{core::MapEntry::value});
   } =>#t18;
   core::List<dynamic>* lhs21 = block {
     final core::List<dynamic>* #t20 = <dynamic>[];
     for (final dynamic #t21 in (spread as dynamic) as{TypeError,ForDynamic} core::Iterable<dynamic>*)
-      #t20.{core::List::add}(#t21);
+      #t20.{core::List::add}{Invariant}(#t21);
   } =>#t20;
   core::Set<dynamic>* set21 = block {
     final core::Set<dynamic>* #t22 = col::LinkedHashSet::•<dynamic>();
     for (final dynamic #t23 in (spread as dynamic) as{TypeError,ForDynamic} core::Iterable<dynamic>*)
-      #t22.{core::Set::add}(#t23);
-    #t22.{core::Set::add}(42);
+      #t22.{core::Set::add}{Invariant}(#t23);
+    #t22.{core::Set::add}{Invariant}(42);
   } =>#t22;
   core::Map<dynamic, dynamic>* map21 = block {
     final core::Map<dynamic, dynamic>* #t24 = <dynamic, dynamic>{};
     for (final core::MapEntry<dynamic, dynamic>* #t25 in ((mapSpread as dynamic) as{TypeError,ForDynamic} core::Map<dynamic, dynamic>*).{core::Map::entries})
-      #t24.{core::Map::[]=}(#t25.{core::MapEntry::key}, #t25.{core::MapEntry::value});
-    #t24.{core::Map::[]=}("baz", 42);
+      #t24.{core::Map::[]=}{Invariant}(#t25.{core::MapEntry::key}, #t25.{core::MapEntry::value});
+    #t24.{core::Map::[]=}{Invariant}("baz", 42);
   } =>#t24;
   dynamic map21ambiguous = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:66:28: Error: Not enough type information to disambiguate between literal set and literal map.
 Try providing type arguments for the literal explicitly to disambiguate it.
@@ -182,48 +182,48 @@
   core::List<core::int*>* lhs22 = block {
     final core::List<core::int*>* #t26 = <core::int*>[];
     for (final core::int* #t27 in <core::int*>[])
-      #t26.{core::List::add}(#t27);
+      #t26.{core::List::add}{Invariant}(#t27);
   } =>#t26;
   core::Set<core::int*>* set22 = block {
     final core::Set<core::int*>* #t28 = col::LinkedHashSet::•<core::int*>();
     for (final core::int* #t29 in <core::int*>[])
-      #t28.{core::Set::add}(#t29);
-    #t28.{core::Set::add}(42);
+      #t28.{core::Set::add}{Invariant}(#t29);
+    #t28.{core::Set::add}{Invariant}(42);
   } =>#t28;
   core::Set<core::int*>* set22ambiguous = block {
     final core::Set<core::int*>* #t30 = col::LinkedHashSet::•<core::int*>();
     for (final dynamic #t31 in <core::int*>[]) {
       final core::int* #t32 = #t31 as{TypeError} core::int*;
-      #t30.{core::Set::add}(#t32);
+      #t30.{core::Set::add}{Invariant}(#t32);
     }
   } =>#t30;
   core::Map<core::String*, core::int*>* map22 = block {
     final core::Map<core::String*, core::int*>* #t33 = <core::String*, core::int*>{};
     for (final core::MapEntry<core::String*, core::int*>* #t34 in <core::String*, core::int*>{}.{core::Map::entries})
-      #t33.{core::Map::[]=}(#t34.{core::MapEntry::key}, #t34.{core::MapEntry::value});
+      #t33.{core::Map::[]=}{Invariant}(#t34.{core::MapEntry::key}, #t34.{core::MapEntry::value});
   } =>#t33;
   core::List<core::List<core::int*>*>* lhs23 = block {
     final core::List<core::List<core::int*>*>* #t35 = <core::List<core::int*>*>[];
     for (final core::List<core::int*>* #t36 in <core::List<core::int*>*>[<core::int*>[]])
-      #t35.{core::List::add}(#t36);
+      #t35.{core::List::add}{Invariant}(#t36);
   } =>#t35;
   core::Set<core::List<core::int*>*>* set23 = block {
     final core::Set<core::List<core::int*>*>* #t37 = col::LinkedHashSet::•<core::List<core::int*>*>();
     for (final core::List<core::int*>* #t38 in <core::List<core::int*>*>[<core::int*>[]])
-      #t37.{core::Set::add}(#t38);
-    #t37.{core::Set::add}(<core::int*>[42]);
+      #t37.{core::Set::add}{Invariant}(#t38);
+    #t37.{core::Set::add}{Invariant}(<core::int*>[42]);
   } =>#t37;
   core::Set<core::List<core::int*>*>* set23ambiguous = block {
     final core::Set<core::List<core::int*>*>* #t39 = col::LinkedHashSet::•<core::List<core::int*>*>();
     for (final dynamic #t40 in <core::List<core::int*>*>[<core::int*>[]]) {
       final core::List<core::int*>* #t41 = #t40 as{TypeError} core::List<core::int*>*;
-      #t39.{core::Set::add}(#t41);
+      #t39.{core::Set::add}{Invariant}(#t41);
     }
   } =>#t39;
   core::Map<core::String*, core::List<core::int*>*>* map23 = block {
     final core::Map<core::String*, core::List<core::int*>*>* #t42 = <core::String*, core::List<core::int*>*>{};
     for (final core::MapEntry<core::String*, core::List<core::int*>*>* #t43 in <core::String*, core::List<core::int*>*>{"baz": <core::int*>[]}.{core::Map::entries})
-      #t42.{core::Map::[]=}(#t43.{core::MapEntry::key}, #t43.{core::MapEntry::value});
+      #t42.{core::Map::[]=}{Invariant}(#t43.{core::MapEntry::key}, #t43.{core::MapEntry::value});
   } =>#t42;
   dynamic map24ambiguous = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:98:28: Error: Both Iterable and Map spread elements encountered in ambiguous literal.
   dynamic map24ambiguous = {...spread, ...mapSpread};
@@ -234,7 +234,7 @@
                                    ^" in ( block {
     final core::List<core::int*>* #t45 = <core::int*>[];
     for (final core::int* #t46 in spread)
-      #t45.{core::List::add}(#t46);
+      #t45.{core::List::add}{Invariant}(#t46);
   } =>#t45) as{TypeError} core::int*;
   core::int* set30 = let final<BottomType> #t47 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:102:36: Error: A value of type 'Set<int>' can't be assigned to a variable of type 'int'.
  - 'Set' is from 'dart:core'.
@@ -242,8 +242,8 @@
                                    ^" in ( block {
     final core::Set<core::int*>* #t48 = col::LinkedHashSet::•<core::int*>();
     for (final core::int* #t49 in spread)
-      #t48.{core::Set::add}(#t49);
-    #t48.{core::Set::add}(42);
+      #t48.{core::Set::add}{Invariant}(#t49);
+    #t48.{core::Set::add}{Invariant}(42);
   } =>#t48) as{TypeError} core::int*;
   core::int* set30ambiguous = let final<BottomType> #t50 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:105:7: Error: A value of type 'Set<int>' can't be assigned to a variable of type 'int'.
  - 'Set' is from 'dart:core'.
@@ -252,7 +252,7 @@
     final core::Set<core::int*>* #t51 = col::LinkedHashSet::•<core::int*>();
     for (final dynamic #t52 in spread) {
       final core::int* #t53 = #t52 as{TypeError} core::int*;
-      #t51.{core::Set::add}(#t53);
+      #t51.{core::Set::add}{Invariant}(#t53);
     }
   } =>#t51) as{TypeError} core::int*;
   core::int* map30 = let final<BottomType> #t54 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:108:7: Error: A value of type 'Map<String, int>' can't be assigned to a variable of type 'int'.
@@ -261,8 +261,8 @@
       ^" in ( block {
     final core::Map<core::String*, core::int*>* #t55 = <core::String*, core::int*>{};
     for (final core::MapEntry<core::String*, core::int*>* #t56 in mapSpread.{core::Map::entries})
-      #t55.{core::Map::[]=}(#t56.{core::MapEntry::key}, #t56.{core::MapEntry::value});
-    #t55.{core::Map::[]=}("baz", 42);
+      #t55.{core::Map::[]=}{Invariant}(#t56.{core::MapEntry::key}, #t56.{core::MapEntry::value});
+    #t55.{core::Map::[]=}{Invariant}("baz", 42);
   } =>#t55) as{TypeError} core::int*;
   core::int* map30ambiguous = let final<BottomType> #t57 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:111:7: Error: A value of type 'Map<String, int>' can't be assigned to a variable of type 'int'.
  - 'Map' is from 'dart:core'.
@@ -270,14 +270,14 @@
       ^" in ( block {
     final core::Map<core::String*, core::int*>* #t58 = <core::String*, core::int*>{};
     for (final core::MapEntry<core::String*, core::int*>* #t59 in mapSpread.{core::Map::entries})
-      #t58.{core::Map::[]=}(#t59.{core::MapEntry::key}, #t59.{core::MapEntry::value});
+      #t58.{core::Map::[]=}{Invariant}(#t59.{core::MapEntry::key}, #t59.{core::MapEntry::value});
   } =>#t58) as{TypeError} core::int*;
   core::List<dynamic>* lhs40 = <dynamic>[invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:113:38: Error: Unexpected type 'int' of a spread.  Expected 'dynamic' or an Iterable.
   List<dynamic> lhs40 = <dynamic>[...notSpreadInt];
                                      ^"];
   core::Set<dynamic>* set40 = block {
     final core::Set<dynamic>* #t60 = col::LinkedHashSet::•<dynamic>();
-    #t60.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:115:37: Error: Unexpected type 'int' of a spread.  Expected 'dynamic' or an Iterable.
+    #t60.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:115:37: Error: Unexpected type 'int' of a spread.  Expected 'dynamic' or an Iterable.
   Set<dynamic> set40 = <dynamic>{...notSpreadInt};
                                     ^");
   } =>#t60;
@@ -289,7 +289,7 @@
                                      ^"];
   core::Set<dynamic>* set50 = block {
     final core::Set<dynamic>* #t61 = col::LinkedHashSet::•<dynamic>();
-    #t61.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:121:37: Error: Unexpected type 'int Function()' of a spread.  Expected 'dynamic' or an Iterable.
+    #t61.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:121:37: Error: Unexpected type 'int Function()' of a spread.  Expected 'dynamic' or an Iterable.
   Set<dynamic> set50 = <dynamic>{...notSpreadFunction};
                                     ^");
   } =>#t61;
@@ -301,7 +301,7 @@
                                    ^"];
   core::Set<core::String*>* set60 = block {
     final core::Set<core::String*>* #t62 = col::LinkedHashSet::•<core::String*>();
-    #t62.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:127:35: Error: Can't assign spread elements of type 'int' to collection elements of type 'String'.
+    #t62.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:127:35: Error: Can't assign spread elements of type 'int' to collection elements of type 'String'.
   Set<String> set60 = <String>{...spread};
                                   ^");
   } =>#t62;
@@ -316,18 +316,18 @@
                              ^"];
   core::Set<core::int*>* set70 = block {
     final core::Set<core::int*>* #t63 = col::LinkedHashSet::•<core::int*>();
-    #t63.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:135:29: Error: Can't spread a value with static type 'Null'.
+    #t63.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:135:29: Error: Can't spread a value with static type 'Null'.
   Set<int> set70 = <int>{...null};
                             ^");
   } =>#t63;
   core::Set<dynamic>* set71ambiguous = block {
     final core::Set<dynamic>* #t64 = col::LinkedHashSet::•<dynamic>();
-    #t64.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:139:8: Error: Expected ',' before this.
+    #t64.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:139:8: Error: Expected ',' before this.
     ...null,
        ^");
     for (final dynamic #t65 in <dynamic>[]) {
       final dynamic #t66 = #t65 as{TypeError} dynamic;
-      #t64.{core::Set::add}(#t66);
+      #t64.{core::Set::add}{Invariant}(#t66);
     }
   } =>#t64;
   core::Map<core::String*, core::int*>* map70 = <core::String*, core::int*>{invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:144:45: Error: Can't spread a value with static type 'Null'.
@@ -338,14 +338,14 @@
     final core::Iterable<core::int*>* #t68 = null;
     if(!#t68.{core::Object::==}(null))
       for (final core::int* #t69 in #t68)
-        #t67.{core::List::add}(#t69);
+        #t67.{core::List::add}{Invariant}(#t69);
   } =>#t67;
   core::Set<core::int*>* set80 = block {
     final core::Set<core::int*>* #t70 = col::LinkedHashSet::•<core::int*>();
     final core::Iterable<core::int*>* #t71 = null;
     if(!#t71.{core::Object::==}(null))
       for (final core::int* #t72 in #t71)
-        #t70.{core::Set::add}(#t72);
+        #t70.{core::Set::add}{Invariant}(#t72);
   } =>#t70;
   core::Set<dynamic>* set81ambiguous = block {
     final core::Set<dynamic>* #t73 = col::LinkedHashSet::•<dynamic>();
@@ -353,11 +353,11 @@
     if(!#t74.{core::Object::==}(null))
       for (final dynamic #t75 in #t74) {
         final dynamic #t76 = #t75 as{TypeError} dynamic;
-        #t73.{core::Set::add}(#t76);
+        #t73.{core::Set::add}{Invariant}(#t76);
       }
     for (final dynamic #t77 in <dynamic>[]) {
       final dynamic #t78 = #t77 as{TypeError} dynamic;
-      #t73.{core::Set::add}(#t78);
+      #t73.{core::Set::add}{Invariant}(#t78);
     }
   } =>#t73;
   core::Map<core::String*, core::int*>* map80 = block {
@@ -365,18 +365,18 @@
     final core::Map<core::String*, core::int*>* #t80 = null;
     if(!#t80.{core::Object::==}(null))
       for (final core::MapEntry<core::String*, core::int*>* #t81 in #t80.{core::Map::entries})
-        #t79.{core::Map::[]=}(#t81.{core::MapEntry::key}, #t81.{core::MapEntry::value});
+        #t79.{core::Map::[]=}{Invariant}(#t81.{core::MapEntry::key}, #t81.{core::MapEntry::value});
   } =>#t79;
   core::Map<core::String*, core::int*>* map90 = block {
     final core::Map<core::String*, core::int*>* #t82 = <core::String*, core::int*>{};
     for (final core::MapEntry<core::String*, core::int*>* #t83 in self::bar<core::String*, core::int*>().{core::Map::entries})
-      #t82.{core::Map::[]=}(#t83.{core::MapEntry::key}, #t83.{core::MapEntry::value});
+      #t82.{core::Map::[]=}{Invariant}(#t83.{core::MapEntry::key}, #t83.{core::MapEntry::value});
   } =>#t82;
   core::List<core::int*>* list100 = block {
     final core::List<core::int*>* #t84 = <core::int*>[];
     for (final dynamic #t85 in listNum) {
       final core::int* #t86 = #t85 as{TypeError} core::int*;
-      #t84.{core::List::add}(#t86);
+      #t84.{core::List::add}{Invariant}(#t86);
     }
   } =>#t84;
   core::Map<core::num*, core::int*>* map100 = block {
@@ -384,14 +384,14 @@
     for (final core::MapEntry<dynamic, dynamic>* #t88 in mapIntNum.{core::Map::entries}) {
       final core::num* #t89 = #t88.{core::MapEntry::key} as{TypeError} core::num*;
       final core::int* #t90 = #t88.{core::MapEntry::value} as{TypeError} core::int*;
-      #t87.{core::Map::[]=}(#t89, #t90);
+      #t87.{core::Map::[]=}{Invariant}(#t89, #t90);
     }
   } =>#t87;
   core::List<core::int*>* list110 = block {
     final core::List<core::int*>* #t91 = <core::int*>[];
     for (final dynamic #t92 in dynVar as{TypeError,ForDynamic} core::Iterable<dynamic>*) {
       final core::int* #t93 = #t92 as{TypeError} core::int*;
-      #t91.{core::List::add}(#t93);
+      #t91.{core::List::add}{Invariant}(#t93);
     }
   } =>#t91;
   core::Map<core::num*, core::int*>* map110 = block {
@@ -399,7 +399,7 @@
     for (final core::MapEntry<dynamic, dynamic>* #t95 in (dynVar as{TypeError,ForDynamic} core::Map<dynamic, dynamic>*).{core::Map::entries}) {
       final core::num* #t96 = #t95.{core::MapEntry::key} as{TypeError} core::num*;
       final core::int* #t97 = #t95.{core::MapEntry::value} as{TypeError} core::int*;
-      #t94.{core::Map::[]=}(#t96, #t97);
+      #t94.{core::Map::[]=}{Invariant}(#t96, #t97);
     }
   } =>#t94;
 }
diff --git a/pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart.weak.transformed.expect b/pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart.weak.transformed.expect
index 8ba5c53..4cafcc2 100644
--- a/pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart.weak.transformed.expect
@@ -115,7 +115,7 @@
       core::Iterator<dynamic>* :sync-for-iterator = <dynamic>[].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final dynamic #t2 = :sync-for-iterator.{core::Iterator::current};
-        #t1.{core::List::add}(#t2);
+        #t1.{core::List::add}{Invariant}(#t2);
       }
     }
   } =>#t1;
@@ -125,7 +125,7 @@
       core::Iterator<dynamic>* :sync-for-iterator = <dynamic>[].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final dynamic #t4 = :sync-for-iterator.{core::Iterator::current};
-        #t3.{core::Set::add}(#t4);
+        #t3.{core::Set::add}{Invariant}(#t4);
       }
     }
   } =>#t3;
@@ -135,7 +135,7 @@
       core::Iterator<core::MapEntry<dynamic, dynamic>>* :sync-for-iterator = <dynamic, dynamic>{}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<dynamic, dynamic>* #t6 = :sync-for-iterator.{core::Iterator::current};
-        #t5.{core::Map::[]=}(#t6.{core::MapEntry::key}, #t6.{core::MapEntry::value});
+        #t5.{core::Map::[]=}{Invariant}(#t6.{core::MapEntry::key}, #t6.{core::MapEntry::value});
       }
     }
   } =>#t5;
@@ -145,7 +145,7 @@
       core::Iterator<core::MapEntry<dynamic, dynamic>>* :sync-for-iterator = <dynamic, dynamic>{}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<dynamic, dynamic>* #t8 = :sync-for-iterator.{core::Iterator::current};
-        #t7.{core::Map::[]=}(#t8.{core::MapEntry::key}, #t8.{core::MapEntry::value});
+        #t7.{core::Map::[]=}{Invariant}(#t8.{core::MapEntry::key}, #t8.{core::MapEntry::value});
       }
     }
   } =>#t7;
@@ -155,7 +155,7 @@
       core::Iterator<core::int*>* :sync-for-iterator = spread.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t10 = :sync-for-iterator.{core::Iterator::current};
-        #t9.{core::List::add}(#t10);
+        #t9.{core::List::add}{Invariant}(#t10);
       }
     }
   } =>#t9;
@@ -165,10 +165,10 @@
       core::Iterator<core::int*>* :sync-for-iterator = spread.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t12 = :sync-for-iterator.{core::Iterator::current};
-        #t11.{core::Set::add}(#t12);
+        #t11.{core::Set::add}{Invariant}(#t12);
       }
     }
-    #t11.{core::Set::add}(42);
+    #t11.{core::Set::add}{Invariant}(42);
   } =>#t11;
   core::Set<core::int*>* set20ambiguous = block {
     final core::Set<core::int*>* #t13 = new col::_CompactLinkedHashSet::•<core::int*>();
@@ -178,7 +178,7 @@
         final dynamic #t14 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int* #t15 = #t14 as{TypeError} core::int*;
-          #t13.{core::Set::add}(#t15);
+          #t13.{core::Set::add}{Invariant}(#t15);
         }
       }
     }
@@ -189,10 +189,10 @@
       core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = mapSpread.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::int*>* #t17 = :sync-for-iterator.{core::Iterator::current};
-        #t16.{core::Map::[]=}(#t17.{core::MapEntry::key}, #t17.{core::MapEntry::value});
+        #t16.{core::Map::[]=}{Invariant}(#t17.{core::MapEntry::key}, #t17.{core::MapEntry::value});
       }
     }
-    #t16.{core::Map::[]=}("baz", 42);
+    #t16.{core::Map::[]=}{Invariant}("baz", 42);
   } =>#t16;
   core::Map<core::String*, core::int*>* map20ambiguous = block {
     final core::Map<core::String*, core::int*>* #t18 = <core::String*, core::int*>{};
@@ -200,7 +200,7 @@
       core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = mapSpread.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::int*>* #t19 = :sync-for-iterator.{core::Iterator::current};
-        #t18.{core::Map::[]=}(#t19.{core::MapEntry::key}, #t19.{core::MapEntry::value});
+        #t18.{core::Map::[]=}{Invariant}(#t19.{core::MapEntry::key}, #t19.{core::MapEntry::value});
       }
     }
   } =>#t18;
@@ -210,7 +210,7 @@
       core::Iterator<dynamic>* :sync-for-iterator = ((spread as dynamic) as{TypeError,ForDynamic} core::Iterable<dynamic>*).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final dynamic #t21 = :sync-for-iterator.{core::Iterator::current};
-        #t20.{core::List::add}(#t21);
+        #t20.{core::List::add}{Invariant}(#t21);
       }
     }
   } =>#t20;
@@ -220,10 +220,10 @@
       core::Iterator<dynamic>* :sync-for-iterator = ((spread as dynamic) as{TypeError,ForDynamic} core::Iterable<dynamic>*).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final dynamic #t23 = :sync-for-iterator.{core::Iterator::current};
-        #t22.{core::Set::add}(#t23);
+        #t22.{core::Set::add}{Invariant}(#t23);
       }
     }
-    #t22.{core::Set::add}(42);
+    #t22.{core::Set::add}{Invariant}(42);
   } =>#t22;
   core::Map<dynamic, dynamic>* map21 = block {
     final core::Map<dynamic, dynamic>* #t24 = <dynamic, dynamic>{};
@@ -231,10 +231,10 @@
       core::Iterator<core::MapEntry<dynamic, dynamic>>* :sync-for-iterator = ((mapSpread as dynamic) as{TypeError,ForDynamic} core::Map<dynamic, dynamic>*).{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<dynamic, dynamic>* #t25 = :sync-for-iterator.{core::Iterator::current};
-        #t24.{core::Map::[]=}(#t25.{core::MapEntry::key}, #t25.{core::MapEntry::value});
+        #t24.{core::Map::[]=}{Invariant}(#t25.{core::MapEntry::key}, #t25.{core::MapEntry::value});
       }
     }
-    #t24.{core::Map::[]=}("baz", 42);
+    #t24.{core::Map::[]=}{Invariant}("baz", 42);
   } =>#t24;
   dynamic map21ambiguous = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:66:28: Error: Not enough type information to disambiguate between literal set and literal map.
 Try providing type arguments for the literal explicitly to disambiguate it.
@@ -246,7 +246,7 @@
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t27 = :sync-for-iterator.{core::Iterator::current};
-        #t26.{core::List::add}(#t27);
+        #t26.{core::List::add}{Invariant}(#t27);
       }
     }
   } =>#t26;
@@ -256,10 +256,10 @@
       core::Iterator<core::int*>* :sync-for-iterator = <core::int*>[].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t29 = :sync-for-iterator.{core::Iterator::current};
-        #t28.{core::Set::add}(#t29);
+        #t28.{core::Set::add}{Invariant}(#t29);
       }
     }
-    #t28.{core::Set::add}(42);
+    #t28.{core::Set::add}{Invariant}(42);
   } =>#t28;
   core::Set<core::int*>* set22ambiguous = block {
     final core::Set<core::int*>* #t30 = new col::_CompactLinkedHashSet::•<core::int*>();
@@ -269,7 +269,7 @@
         final dynamic #t31 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int* #t32 = #t31 as{TypeError} core::int*;
-          #t30.{core::Set::add}(#t32);
+          #t30.{core::Set::add}{Invariant}(#t32);
         }
       }
     }
@@ -280,7 +280,7 @@
       core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = <core::String*, core::int*>{}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::int*>* #t34 = :sync-for-iterator.{core::Iterator::current};
-        #t33.{core::Map::[]=}(#t34.{core::MapEntry::key}, #t34.{core::MapEntry::value});
+        #t33.{core::Map::[]=}{Invariant}(#t34.{core::MapEntry::key}, #t34.{core::MapEntry::value});
       }
     }
   } =>#t33;
@@ -290,7 +290,7 @@
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t36 = :sync-for-iterator.{core::Iterator::current};
-        #t35.{core::List::add}(#t36);
+        #t35.{core::List::add}{Invariant}(#t36);
       }
     }
   } =>#t35;
@@ -300,10 +300,10 @@
       core::Iterator<core::List<core::int*>*>* :sync-for-iterator = <core::List<core::int*>*>[<core::int*>[]].{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::List<core::int*>* #t38 = :sync-for-iterator.{core::Iterator::current};
-        #t37.{core::Set::add}(#t38);
+        #t37.{core::Set::add}{Invariant}(#t38);
       }
     }
-    #t37.{core::Set::add}(<core::int*>[42]);
+    #t37.{core::Set::add}{Invariant}(<core::int*>[42]);
   } =>#t37;
   core::Set<core::List<core::int*>*>* set23ambiguous = block {
     final core::Set<core::List<core::int*>*>* #t39 = new col::_CompactLinkedHashSet::•<core::List<core::int*>*>();
@@ -313,7 +313,7 @@
         final dynamic #t40 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::List<core::int*>* #t41 = #t40 as{TypeError} core::List<core::int*>*;
-          #t39.{core::Set::add}(#t41);
+          #t39.{core::Set::add}{Invariant}(#t41);
         }
       }
     }
@@ -324,7 +324,7 @@
       core::Iterator<core::MapEntry<core::String*, core::List<core::int*>*>>* :sync-for-iterator = <core::String*, core::List<core::int*>*>{"baz": <core::int*>[]}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::List<core::int*>*>* #t43 = :sync-for-iterator.{core::Iterator::current};
-        #t42.{core::Map::[]=}(#t43.{core::MapEntry::key}, #t43.{core::MapEntry::value});
+        #t42.{core::Map::[]=}{Invariant}(#t43.{core::MapEntry::key}, #t43.{core::MapEntry::value});
       }
     }
   } =>#t42;
@@ -340,7 +340,7 @@
       core::Iterator<core::int*>* :sync-for-iterator = spread.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t46 = :sync-for-iterator.{core::Iterator::current};
-        #t45.{core::List::add}(#t46);
+        #t45.{core::List::add}{Invariant}(#t46);
       }
     }
   } =>#t45) as{TypeError} core::int*;
@@ -353,10 +353,10 @@
       core::Iterator<core::int*>* :sync-for-iterator = spread.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t49 = :sync-for-iterator.{core::Iterator::current};
-        #t48.{core::Set::add}(#t49);
+        #t48.{core::Set::add}{Invariant}(#t49);
       }
     }
-    #t48.{core::Set::add}(42);
+    #t48.{core::Set::add}{Invariant}(42);
   } =>#t48) as{TypeError} core::int*;
   core::int* set30ambiguous = let final<BottomType> #t50 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:105:7: Error: A value of type 'Set<int>' can't be assigned to a variable of type 'int'.
  - 'Set' is from 'dart:core'.
@@ -369,7 +369,7 @@
         final dynamic #t52 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int* #t53 = #t52 as{TypeError} core::int*;
-          #t51.{core::Set::add}(#t53);
+          #t51.{core::Set::add}{Invariant}(#t53);
         }
       }
     }
@@ -383,10 +383,10 @@
       core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = mapSpread.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::int*>* #t56 = :sync-for-iterator.{core::Iterator::current};
-        #t55.{core::Map::[]=}(#t56.{core::MapEntry::key}, #t56.{core::MapEntry::value});
+        #t55.{core::Map::[]=}{Invariant}(#t56.{core::MapEntry::key}, #t56.{core::MapEntry::value});
       }
     }
-    #t55.{core::Map::[]=}("baz", 42);
+    #t55.{core::Map::[]=}{Invariant}("baz", 42);
   } =>#t55) as{TypeError} core::int*;
   core::int* map30ambiguous = let final<BottomType> #t57 = invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:111:7: Error: A value of type 'Map<String, int>' can't be assigned to a variable of type 'int'.
  - 'Map' is from 'dart:core'.
@@ -397,7 +397,7 @@
       core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = mapSpread.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::int*>* #t59 = :sync-for-iterator.{core::Iterator::current};
-        #t58.{core::Map::[]=}(#t59.{core::MapEntry::key}, #t59.{core::MapEntry::value});
+        #t58.{core::Map::[]=}{Invariant}(#t59.{core::MapEntry::key}, #t59.{core::MapEntry::value});
       }
     }
   } =>#t58) as{TypeError} core::int*;
@@ -406,7 +406,7 @@
                                      ^"];
   core::Set<dynamic>* set40 = block {
     final core::Set<dynamic>* #t60 = new col::_CompactLinkedHashSet::•<dynamic>();
-    #t60.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:115:37: Error: Unexpected type 'int' of a spread.  Expected 'dynamic' or an Iterable.
+    #t60.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:115:37: Error: Unexpected type 'int' of a spread.  Expected 'dynamic' or an Iterable.
   Set<dynamic> set40 = <dynamic>{...notSpreadInt};
                                     ^");
   } =>#t60;
@@ -418,7 +418,7 @@
                                      ^"];
   core::Set<dynamic>* set50 = block {
     final core::Set<dynamic>* #t61 = new col::_CompactLinkedHashSet::•<dynamic>();
-    #t61.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:121:37: Error: Unexpected type 'int Function()' of a spread.  Expected 'dynamic' or an Iterable.
+    #t61.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:121:37: Error: Unexpected type 'int Function()' of a spread.  Expected 'dynamic' or an Iterable.
   Set<dynamic> set50 = <dynamic>{...notSpreadFunction};
                                     ^");
   } =>#t61;
@@ -430,7 +430,7 @@
                                    ^"];
   core::Set<core::String*>* set60 = block {
     final core::Set<core::String*>* #t62 = new col::_CompactLinkedHashSet::•<core::String*>();
-    #t62.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:127:35: Error: Can't assign spread elements of type 'int' to collection elements of type 'String'.
+    #t62.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:127:35: Error: Can't assign spread elements of type 'int' to collection elements of type 'String'.
   Set<String> set60 = <String>{...spread};
                                   ^");
   } =>#t62;
@@ -445,13 +445,13 @@
                              ^"];
   core::Set<core::int*>* set70 = block {
     final core::Set<core::int*>* #t63 = new col::_CompactLinkedHashSet::•<core::int*>();
-    #t63.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:135:29: Error: Can't spread a value with static type 'Null'.
+    #t63.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:135:29: Error: Can't spread a value with static type 'Null'.
   Set<int> set70 = <int>{...null};
                             ^");
   } =>#t63;
   core::Set<dynamic>* set71ambiguous = block {
     final core::Set<dynamic>* #t64 = new col::_CompactLinkedHashSet::•<dynamic>();
-    #t64.{core::Set::add}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:139:8: Error: Expected ',' before this.
+    #t64.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/general_nnbd_opt_out/spread_collection_inference.dart:139:8: Error: Expected ',' before this.
     ...null,
        ^");
     {
@@ -460,7 +460,7 @@
         final dynamic #t65 = :sync-for-iterator.{core::Iterator::current};
         {
           final dynamic #t66 = #t65 as{TypeError} dynamic;
-          #t64.{core::Set::add}(#t66);
+          #t64.{core::Set::add}{Invariant}(#t66);
         }
       }
     }
@@ -475,7 +475,7 @@
       core::Iterator<core::int*>* :sync-for-iterator = #t68.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t69 = :sync-for-iterator.{core::Iterator::current};
-        #t67.{core::List::add}(#t69);
+        #t67.{core::List::add}{Invariant}(#t69);
       }
     }
   } =>#t67;
@@ -486,7 +486,7 @@
       core::Iterator<core::int*>* :sync-for-iterator = #t71.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int* #t72 = :sync-for-iterator.{core::Iterator::current};
-        #t70.{core::Set::add}(#t72);
+        #t70.{core::Set::add}{Invariant}(#t72);
       }
     }
   } =>#t70;
@@ -499,7 +499,7 @@
         final dynamic #t75 = :sync-for-iterator.{core::Iterator::current};
         {
           final dynamic #t76 = #t75 as{TypeError} dynamic;
-          #t73.{core::Set::add}(#t76);
+          #t73.{core::Set::add}{Invariant}(#t76);
         }
       }
     }
@@ -509,7 +509,7 @@
         final dynamic #t77 = :sync-for-iterator.{core::Iterator::current};
         {
           final dynamic #t78 = #t77 as{TypeError} dynamic;
-          #t73.{core::Set::add}(#t78);
+          #t73.{core::Set::add}{Invariant}(#t78);
         }
       }
     }
@@ -521,7 +521,7 @@
       core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = #t80.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::int*>* #t81 = :sync-for-iterator.{core::Iterator::current};
-        #t79.{core::Map::[]=}(#t81.{core::MapEntry::key}, #t81.{core::MapEntry::value});
+        #t79.{core::Map::[]=}{Invariant}(#t81.{core::MapEntry::key}, #t81.{core::MapEntry::value});
       }
     }
   } =>#t79;
@@ -531,7 +531,7 @@
       core::Iterator<core::MapEntry<core::String*, core::int*>>* :sync-for-iterator = self::bar<core::String*, core::int*>().{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String*, core::int*>* #t83 = :sync-for-iterator.{core::Iterator::current};
-        #t82.{core::Map::[]=}(#t83.{core::MapEntry::key}, #t83.{core::MapEntry::value});
+        #t82.{core::Map::[]=}{Invariant}(#t83.{core::MapEntry::key}, #t83.{core::MapEntry::value});
       }
     }
   } =>#t82;
@@ -543,7 +543,7 @@
         final dynamic #t85 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int* #t86 = #t85 as{TypeError} core::int*;
-          #t84.{core::List::add}(#t86);
+          #t84.{core::List::add}{Invariant}(#t86);
         }
       }
     }
@@ -557,7 +557,7 @@
         {
           final core::num* #t89 = #t88.{core::MapEntry::key} as{TypeError} core::num*;
           final core::int* #t90 = #t88.{core::MapEntry::value} as{TypeError} core::int*;
-          #t87.{core::Map::[]=}(#t89, #t90);
+          #t87.{core::Map::[]=}{Invariant}(#t89, #t90);
         }
       }
     }
@@ -570,7 +570,7 @@
         final dynamic #t92 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int* #t93 = #t92 as{TypeError} core::int*;
-          #t91.{core::List::add}(#t93);
+          #t91.{core::List::add}{Invariant}(#t93);
         }
       }
     }
@@ -584,7 +584,7 @@
         {
           final core::num* #t96 = #t95.{core::MapEntry::key} as{TypeError} core::num*;
           final core::int* #t97 = #t95.{core::MapEntry::value} as{TypeError} core::int*;
-          #t94.{core::Map::[]=}(#t96, #t97);
+          #t94.{core::Map::[]=}{Invariant}(#t96, #t97);
         }
       }
     }
diff --git a/pkg/front_end/testcases/incremental_initialize_from_dill/no_outline_change_22.yaml.world.1.expect b/pkg/front_end/testcases/incremental_initialize_from_dill/no_outline_change_22.yaml.world.1.expect
index 93245f5..994228a 100644
--- a/pkg/front_end/testcases/incremental_initialize_from_dill/no_outline_change_22.yaml.world.1.expect
+++ b/pkg/front_end/testcases/incremental_initialize_from_dill/no_outline_change_22.yaml.world.1.expect
@@ -322,14 +322,14 @@
           dart.core::Iterator<dart.core::int*> :sync-for-iterator = this.{dart.core::Iterable::iterator};
           for (; :sync-for-iterator.{dart.core::Iterator::moveNext}(); ) {
             final dart.core::int* #t6 = :sync-for-iterator.{dart.core::Iterator::current};
-            #t5.{dart.core::List::add}(#t6);
+            #t5.{dart.core::List::add}{Invariant}(#t6);
           }
         }
         {
           dart.core::Iterator<dart.core::int*> :sync-for-iterator = other.{dart.core::Iterable::iterator};
           for (; :sync-for-iterator.{dart.core::Iterator::moveNext}(); ) {
             final dart.core::int* #t7 = :sync-for-iterator.{dart.core::Iterator::current};
-            #t5.{dart.core::List::add}(#t7);
+            #t5.{dart.core::List::add}{Invariant}(#t7);
           }
         }
       } =>#t5;
diff --git a/pkg/front_end/testcases/incremental_initialize_from_dill/no_outline_change_22.yaml.world.2.expect b/pkg/front_end/testcases/incremental_initialize_from_dill/no_outline_change_22.yaml.world.2.expect
index 93245f5..994228a 100644
--- a/pkg/front_end/testcases/incremental_initialize_from_dill/no_outline_change_22.yaml.world.2.expect
+++ b/pkg/front_end/testcases/incremental_initialize_from_dill/no_outline_change_22.yaml.world.2.expect
@@ -322,14 +322,14 @@
           dart.core::Iterator<dart.core::int*> :sync-for-iterator = this.{dart.core::Iterable::iterator};
           for (; :sync-for-iterator.{dart.core::Iterator::moveNext}(); ) {
             final dart.core::int* #t6 = :sync-for-iterator.{dart.core::Iterator::current};
-            #t5.{dart.core::List::add}(#t6);
+            #t5.{dart.core::List::add}{Invariant}(#t6);
           }
         }
         {
           dart.core::Iterator<dart.core::int*> :sync-for-iterator = other.{dart.core::Iterable::iterator};
           for (; :sync-for-iterator.{dart.core::Iterator::moveNext}(); ) {
             final dart.core::int* #t7 = :sync-for-iterator.{dart.core::Iterator::current};
-            #t5.{dart.core::List::add}(#t7);
+            #t5.{dart.core::List::add}{Invariant}(#t7);
           }
         }
       } =>#t5;
diff --git a/pkg/front_end/testcases/late_lowering/later.dart.strong.expect b/pkg/front_end/testcases/late_lowering/later.dart.strong.expect
index 0c77ea3..1876a7a 100644
--- a/pkg/front_end/testcases/late_lowering/later.dart.strong.expect
+++ b/pkg/front_end/testcases/late_lowering/later.dart.strong.expect
@@ -127,7 +127,7 @@
   block {
     final core::List<core::int> #t7 = <core::int>[];
     for (core::int i = 0; i.{core::num::<}(10); i = i.{core::num::+}(1))
-      #t7.{core::List::add}(i);
+      #t7.{core::List::add}{Invariant}(i);
   } =>#t7;
 }
 static method hest() → dynamic async {
diff --git a/pkg/front_end/testcases/late_lowering/later.dart.strong.transformed.expect b/pkg/front_end/testcases/late_lowering/later.dart.strong.transformed.expect
index 23a4434..d9e572e 100644
--- a/pkg/front_end/testcases/late_lowering/later.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/late_lowering/later.dart.strong.transformed.expect
@@ -133,7 +133,7 @@
   block {
     final core::List<core::int> #t7 = <core::int>[];
     for (core::int i = 0; i.{core::num::<}(10); i = i.{core::num::+}(1))
-      #t7.{core::List::add}(i);
+      #t7.{core::List::add}{Invariant}(i);
   } =>#t7;
 }
 static method hest() → dynamic /* originally async */ {
diff --git a/pkg/front_end/testcases/late_lowering/later.dart.weak.expect b/pkg/front_end/testcases/late_lowering/later.dart.weak.expect
index 89130dc..267e384 100644
--- a/pkg/front_end/testcases/late_lowering/later.dart.weak.expect
+++ b/pkg/front_end/testcases/late_lowering/later.dart.weak.expect
@@ -147,7 +147,7 @@
   block {
     final core::List<core::int> #t7 = <core::int>[];
     for (core::int i = 0; i.{core::num::<}(10); i = i.{core::num::+}(1))
-      #t7.{core::List::add}(i);
+      #t7.{core::List::add}{Invariant}(i);
   } =>#t7;
 }
 static method hest() → dynamic async {
diff --git a/pkg/front_end/testcases/late_lowering/later.dart.weak.transformed.expect b/pkg/front_end/testcases/late_lowering/later.dart.weak.transformed.expect
index 03aa850..abfa48e 100644
--- a/pkg/front_end/testcases/late_lowering/later.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/late_lowering/later.dart.weak.transformed.expect
@@ -153,7 +153,7 @@
   block {
     final core::List<core::int> #t7 = <core::int>[];
     for (core::int i = 0; i.{core::num::<}(10); i = i.{core::num::+}(1))
-      #t7.{core::List::add}(i);
+      #t7.{core::List::add}{Invariant}(i);
   } =>#t7;
 }
 static method hest() → dynamic /* originally async */ {
diff --git a/pkg/front_end/testcases/nnbd/assignability_error_messages.dart b/pkg/front_end/testcases/nnbd/assignability_error_messages.dart
index 495a9cc..ee2a051 100644
--- a/pkg/front_end/testcases/nnbd/assignability_error_messages.dart
+++ b/pkg/front_end/testcases/nnbd/assignability_error_messages.dart
@@ -5,6 +5,8 @@
 // The test checks that if one type isn't assignable to the other only because
 // of the nullability modifiers, the error message reflects that.
 
+import 'dart:async';
+
 class A {
   const A();
 }
@@ -36,6 +38,14 @@
     default:
       break;
   }
+  FutureOr<A> local() async {
+    if (true) {
+      return x; // Error.
+    } else {
+      return new Future<B?>.value(x); // Error.
+    }
+  }
+
   return x; // Error.
 }
 
@@ -52,4 +62,23 @@
   bazContext(c);
 }
 
+A boz(Null x) {
+  fooContext(x); // Error.
+  fooContext(null); // Error.
+  A a1 = x; // Error.
+  A a2 = null; // Error.
+  if (true) {
+    return x; // Error.
+  } else {
+    return null; // Error.
+  }
+  FutureOr<A> local() async {
+    if (true) {
+      return null; // Error.
+    } else {
+      return new Future<Null>.value(null); // Error.
+    }
+  }
+}
+
 main() {}
diff --git a/pkg/front_end/testcases/nnbd/assignability_error_messages.dart.outline.expect b/pkg/front_end/testcases/nnbd/assignability_error_messages.dart.outline.expect
index b4c79d9..9f993af 100644
--- a/pkg/front_end/testcases/nnbd/assignability_error_messages.dart.outline.expect
+++ b/pkg/front_end/testcases/nnbd/assignability_error_messages.dart.outline.expect
@@ -2,6 +2,8 @@
 import self as self;
 import "dart:core" as core;
 
+import "dart:async";
+
 class A extends core::Object /*hasConstConstructor*/  {
   const constructor •() → self::A
     : super core::Object::•()
@@ -29,5 +31,7 @@
   ;
 static method baz(self::C c) → void
   ;
+static method boz(Null x) → self::A
+  ;
 static method main() → dynamic
   ;
diff --git a/pkg/front_end/testcases/nnbd/assignability_error_messages.dart.strong.expect b/pkg/front_end/testcases/nnbd/assignability_error_messages.dart.strong.expect
index d89eb7f..a4b4cdc 100644
--- a/pkg/front_end/testcases/nnbd/assignability_error_messages.dart.strong.expect
+++ b/pkg/front_end/testcases/nnbd/assignability_error_messages.dart.strong.expect
@@ -2,109 +2,122 @@
 //
 // Problems in library:
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:25:14: Error: The argument type 'B?' can't be assigned to the parameter type 'A' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:27:14: Error: The argument type 'B?' can't be assigned to the parameter type 'A' because 'B?' is nullable and 'A' isn't.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   fooContext(x); // Error.
 //              ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:26:9: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:28:9: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   A a = x; // Error.
 //         ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:27:10: Error: Can't assign spread elements of type 'B?' to collection elements of type 'A' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:29:10: Error: Can't assign spread elements of type 'B?' to collection elements of type 'A' because 'B?' is nullable and 'A' isn't.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   <A>[...l]; // Error.
 //          ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:28:10: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:30:10: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
 //   <A>[...l2]; // Error.
 //          ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:29:13: Error: Can't assign spread entry keys of type 'B?' to map entry keys of type 'A' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:31:13: Error: Can't assign spread entry keys of type 'B?' to map entry keys of type 'A' because 'B?' is nullable and 'A' isn't.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   <A, A>{...m}; // Error.
 //             ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:29:13: Error: Can't assign spread entry values of type 'B?' to map entry values of type 'A' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:31:13: Error: Can't assign spread entry values of type 'B?' to map entry values of type 'A' because 'B?' is nullable and 'A' isn't.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   <A, A>{...m}; // Error.
 //             ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:30:13: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:32:13: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
 //   <A, A>{...m2}; // Error.
 //             ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:31:10: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:33:10: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 // Try changing the type of the variable.
 //   for (A y in l) {} // Error.
 //          ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:32:15: Error: The type 'List<B>?' used in the 'for' loop must implement 'Iterable<dynamic>' because 'List<B>?' is nullable and 'Iterable<dynamic>' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:34:15: Error: The type 'List<B>?' used in the 'for' loop must implement 'Iterable<dynamic>' because 'List<B>?' is nullable and 'Iterable<dynamic>' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'Iterable' is from 'dart:core'.
 //   for (A y in l2) {} // Error.
 //               ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:34:16: Error: Type 'A' of the case expression is not a subtype of type 'B?' of this switch expression.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:36:16: Error: Type 'A' of the case expression is not a subtype of type 'B?' of this switch expression.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //     case const A():
 //                ^
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:33:11: Context: The switch expression is here.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:35:11: Context: The switch expression is here.
 //   switch (x) /*  Error. */ {
 //           ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:39:10: Error: A value of type 'B?' can't be returned from a function with return type 'A' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:43:14: Error: A value of type 'B?' can't be returned from an async function with return type 'FutureOr<A>' because 'B?' is nullable and 'FutureOr<A>' isn't.
+//  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//       return x; // Error.
+//              ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:45:18: Error: A value of type 'Future<B?>' can't be returned from an async function with return type 'FutureOr<A>'.
+//  - 'Future' is from 'dart:async'.
+//  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//       return new Future<B?>.value(x); // Error.
+//                  ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:49:10: Error: A value of type 'B?' can't be returned from a function with return type 'A' because 'B?' is nullable and 'A' isn't.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   return x; // Error.
 //          ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:43:14: Error: The argument type 'List<B?>' can't be assigned to the parameter type 'List<A>' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:53:14: Error: The argument type 'List<B?>' can't be assigned to the parameter type 'List<A>' because 'B?' is nullable and 'A' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   barContext(x); // Error.
 //              ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:44:15: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:54:15: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   List<A> y = x; // Error.
 //               ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:45:16: Error: Can't assign spread elements of type 'List<B?>' to collection elements of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:55:16: Error: Can't assign spread elements of type 'List<B?>' to collection elements of type 'List<A>' because 'B?' is nullable and 'A' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   <List<A>>[...l]; // Error.
 //                ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:46:25: Error: Can't assign spread entry keys of type 'List<B?>' to map entry keys of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:56:25: Error: Can't assign spread entry keys of type 'List<B?>' to map entry keys of type 'List<A>' because 'B?' is nullable and 'A' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   <List<A>, List<A>>{...m}; // Error.
 //                         ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:46:25: Error: Can't assign spread entry values of type 'List<B?>' to map entry values of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:56:25: Error: Can't assign spread entry values of type 'List<B?>' to map entry values of type 'List<A>' because 'B?' is nullable and 'A' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   <List<A>, List<A>>{...m}; // Error.
 //                         ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:47:16: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:57:16: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
@@ -112,19 +125,63 @@
 //   for (List<A> y in l) {} // Error.
 //                ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:48:10: Error: A value of type 'List<B?>' can't be returned from a function with return type 'List<A>' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:58:10: Error: A value of type 'List<B?>' can't be returned from a function with return type 'List<A>' because 'B?' is nullable and 'A' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   return x; // Error.
 //          ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:52:14: Error: The argument type 'num? Function()' can't be assigned to the parameter type 'num Function()' because 'num?' is nullable and 'num' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:62:14: Error: The argument type 'num? Function()' can't be assigned to the parameter type 'num Function()' because 'num?' is nullable and 'num' isn't.
 //   bazContext(c);
 //              ^
 //
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:66:14: Error: The argument type 'Null' can't be assigned to the parameter type 'A' because 'A' is not nullable.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//   fooContext(x); // Error.
+//              ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:67:14: Error: The value 'null' can't be assigned to the parameter type 'A' because 'A' is not nullable.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//   fooContext(null); // Error.
+//              ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:68:10: Error: A value of type 'Null' can't be assigned to a variable of type 'A' because 'A' is not nullable.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//   A a1 = x; // Error.
+//          ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:69:10: Error: The value 'null' can't be assigned to a variable of type 'A' because 'A' is not nullable.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//   A a2 = null; // Error.
+//          ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:71:12: Error: A value of type 'Null' can't be returned from a function with return type 'A' because 'A' is not nullable.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//     return x; // Error.
+//            ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:73:12: Error: The value 'null' can't be returned from a function with return type 'A' because 'A' is not nullable.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//     return null; // Error.
+//            ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:77:14: Error: The value 'null' can't be returned from an async function with return type 'FutureOr<A>' because 'FutureOr<A>' is not nullable.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//       return null; // Error.
+//              ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:79:18: Error: A value of type 'Future<Null>' can't be returned from an async function with return type 'FutureOr<A>'.
+//  - 'Future' is from 'dart:async'.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//       return new Future<Null>.value(null); // Error.
+//                  ^
+//
 import self as self;
 import "dart:core" as core;
+import "dart:async" as asy;
+
+import "dart:async";
 
 class A extends core::Object /*hasConstConstructor*/  {
   const constructor •() → self::A
@@ -146,45 +203,45 @@
 static method barContext(core::List<self::A> x) → void {}
 static method bazContext(() → core::num f) → void {}
 static method foo(self::B? x, core::List<self::B?> l, core::Map<self::B?, self::B?> m, core::List<self::B>? l2, core::Map<self::B, self::B>? m2) → self::A {
-  self::fooContext(let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:25:14: Error: The argument type 'B?' can't be assigned to the parameter type 'A' because 'B?' is nullable and 'A' isn't.
+  self::fooContext(let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:27:14: Error: The argument type 'B?' can't be assigned to the parameter type 'A' because 'B?' is nullable and 'A' isn't.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   fooContext(x); // Error.
              ^" in x as{TypeError,ForNonNullableByDefault} self::A);
-  self::A a = let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:26:9: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
+  self::A a = let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:28:9: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   A a = x; // Error.
         ^" in x as{TypeError,ForNonNullableByDefault} self::A;
-  <self::A>[invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:27:10: Error: Can't assign spread elements of type 'B?' to collection elements of type 'A' because 'B?' is nullable and 'A' isn't.
+  <self::A>[invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:29:10: Error: Can't assign spread elements of type 'B?' to collection elements of type 'A' because 'B?' is nullable and 'A' isn't.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   <A>[...l]; // Error.
          ^"];
-  <self::A>[invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:28:10: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+  <self::A>[invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:30:10: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
   <A>[...l2]; // Error.
          ^"];
-  <self::A, self::A>{invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:29:13: Error: Can't assign spread entry keys of type 'B?' to map entry keys of type 'A' because 'B?' is nullable and 'A' isn't.
+  <self::A, self::A>{invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:31:13: Error: Can't assign spread entry keys of type 'B?' to map entry keys of type 'A' because 'B?' is nullable and 'A' isn't.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   <A, A>{...m}; // Error.
-            ^": invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:29:13: Error: Can't assign spread entry values of type 'B?' to map entry values of type 'A' because 'B?' is nullable and 'A' isn't.
+            ^": invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:31:13: Error: Can't assign spread entry values of type 'B?' to map entry values of type 'A' because 'B?' is nullable and 'A' isn't.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   <A, A>{...m}; // Error.
             ^"};
-  <self::A, self::A>{invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:30:13: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+  <self::A, self::A>{invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:32:13: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
   <A, A>{...m2}; // Error.
             ^": null};
   for (final self::B? #t3 in l) {
-    self::A y = let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:31:10: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
+    self::A y = let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:33:10: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 Try changing the type of the variable.
   for (A y in l) {} // Error.
          ^" in #t3 as{TypeError,ForNonNullableByDefault} self::A;
   }
-  for (self::A y in let final<BottomType> #t5 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:32:15: Error: The type 'List<B>?' used in the 'for' loop must implement 'Iterable<dynamic>' because 'List<B>?' is nullable and 'Iterable<dynamic>' isn't.
+  for (self::A y in let final<BottomType> #t5 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:34:15: Error: The type 'List<B>?' used in the 'for' loop must implement 'Iterable<dynamic>' because 'List<B>?' is nullable and 'Iterable<dynamic>' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'Iterable' is from 'dart:core'.
@@ -204,52 +261,69 @@
         break #L1;
       }
   }
-  return let final<BottomType> #t6 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:39:10: Error: A value of type 'B?' can't be returned from a function with return type 'A' because 'B?' is nullable and 'A' isn't.
+  function local() → FutureOr<self::A> async {
+    if(true) {
+      return let final<BottomType> #t6 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:43:14: Error: A value of type 'B?' can't be returned from an async function with return type 'FutureOr<A>' because 'B?' is nullable and 'FutureOr<A>' isn't.
+ - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+      return x; // Error.
+             ^" in x as{TypeError,ForNonNullableByDefault} self::A;
+    }
+    else {
+      return let final<BottomType> #t7 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:45:18: Error: A value of type 'Future<B?>' can't be returned from an async function with return type 'FutureOr<A>'.
+ - 'Future' is from 'dart:async'.
+ - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+      return new Future<B?>.value(x); // Error.
+                 ^" in asy::Future::value<self::B?>(x) as{TypeError,ForNonNullableByDefault} self::A;
+    }
+  }
+  return let final<BottomType> #t8 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:49:10: Error: A value of type 'B?' can't be returned from a function with return type 'A' because 'B?' is nullable and 'A' isn't.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   return x; // Error.
          ^" in x as{TypeError,ForNonNullableByDefault} self::A;
 }
 static method bar(core::List<self::B?> x, core::List<core::List<self::B?>> l, core::Map<core::List<self::B?>, core::List<self::B?>> m) → core::List<self::A> {
-  self::barContext(let final<BottomType> #t7 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:43:14: Error: The argument type 'List<B?>' can't be assigned to the parameter type 'List<A>' because 'B?' is nullable and 'A' isn't.
+  self::barContext(let final<BottomType> #t9 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:53:14: Error: The argument type 'List<B?>' can't be assigned to the parameter type 'List<A>' because 'B?' is nullable and 'A' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   barContext(x); // Error.
              ^" in x as{TypeError,ForNonNullableByDefault} core::List<self::A>);
-  core::List<self::A> y = let final<BottomType> #t8 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:44:15: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+  core::List<self::A> y = let final<BottomType> #t10 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:54:15: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   List<A> y = x; // Error.
               ^" in x as{TypeError,ForNonNullableByDefault} core::List<self::A>;
-  <core::List<self::A>>[invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:45:16: Error: Can't assign spread elements of type 'List<B?>' to collection elements of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+  <core::List<self::A>>[invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:55:16: Error: Can't assign spread elements of type 'List<B?>' to collection elements of type 'List<A>' because 'B?' is nullable and 'A' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   <List<A>>[...l]; // Error.
                ^"];
-  <core::List<self::A>, core::List<self::A>>{invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:46:25: Error: Can't assign spread entry keys of type 'List<B?>' to map entry keys of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+  <core::List<self::A>, core::List<self::A>>{invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:56:25: Error: Can't assign spread entry keys of type 'List<B?>' to map entry keys of type 'List<A>' because 'B?' is nullable and 'A' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   <List<A>, List<A>>{...m}; // Error.
-                        ^": invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:46:25: Error: Can't assign spread entry values of type 'List<B?>' to map entry values of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+                        ^": invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:56:25: Error: Can't assign spread entry values of type 'List<B?>' to map entry values of type 'List<A>' because 'B?' is nullable and 'A' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   <List<A>, List<A>>{...m}; // Error.
                         ^"};
-  for (final core::List<self::B?> #t9 in l) {
-    core::List<self::A> y = let final<BottomType> #t10 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:47:16: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+  for (final core::List<self::B?> #t11 in l) {
+    core::List<self::A> y = let final<BottomType> #t12 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:57:16: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 Try changing the type of the variable.
   for (List<A> y in l) {} // Error.
-               ^" in #t9 as{TypeError,ForNonNullableByDefault} core::List<self::A>;
+               ^" in #t11 as{TypeError,ForNonNullableByDefault} core::List<self::A>;
   }
-  return let final<BottomType> #t11 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:48:10: Error: A value of type 'List<B?>' can't be returned from a function with return type 'List<A>' because 'B?' is nullable and 'A' isn't.
+  return let final<BottomType> #t13 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:58:10: Error: A value of type 'List<B?>' can't be returned from a function with return type 'List<A>' because 'B?' is nullable and 'A' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
@@ -257,9 +331,54 @@
          ^" in x as{TypeError,ForNonNullableByDefault} core::List<self::A>;
 }
 static method baz(self::C c) → void {
-  self::bazContext(let final<BottomType> #t12 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:52:14: Error: The argument type 'num? Function()' can't be assigned to the parameter type 'num Function()' because 'num?' is nullable and 'num' isn't.
+  self::bazContext(let final<BottomType> #t14 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:62:14: Error: The argument type 'num? Function()' can't be assigned to the parameter type 'num Function()' because 'num?' is nullable and 'num' isn't.
   bazContext(c);
-             ^" in (let final self::C #t13 = c in #t13.==(null) ?{() → core::num?} null : #t13.{self::C::call}) as{TypeError,ForNonNullableByDefault} () → core::num);
+             ^" in (let final self::C #t15 = c in #t15.==(null) ?{() → core::num?} null : #t15.{self::C::call}) as{TypeError,ForNonNullableByDefault} () → core::num);
+}
+static method boz(Null x) → self::A {
+  self::fooContext(let final<BottomType> #t16 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:66:14: Error: The argument type 'Null' can't be assigned to the parameter type 'A' because 'A' is not nullable.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+  fooContext(x); // Error.
+             ^" in x as{TypeError,ForNonNullableByDefault} self::A);
+  self::fooContext(let final<BottomType> #t17 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:67:14: Error: The value 'null' can't be assigned to the parameter type 'A' because 'A' is not nullable.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+  fooContext(null); // Error.
+             ^" in null as{TypeError,ForNonNullableByDefault} self::A);
+  self::A a1 = let final<BottomType> #t18 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:68:10: Error: A value of type 'Null' can't be assigned to a variable of type 'A' because 'A' is not nullable.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+  A a1 = x; // Error.
+         ^" in x as{TypeError,ForNonNullableByDefault} self::A;
+  self::A a2 = let final<BottomType> #t19 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:69:10: Error: The value 'null' can't be assigned to a variable of type 'A' because 'A' is not nullable.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+  A a2 = null; // Error.
+         ^" in null as{TypeError,ForNonNullableByDefault} self::A;
+  if(true) {
+    return let final<BottomType> #t20 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:71:12: Error: A value of type 'Null' can't be returned from a function with return type 'A' because 'A' is not nullable.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+    return x; // Error.
+           ^" in x as{TypeError,ForNonNullableByDefault} self::A;
+  }
+  else {
+    return let final<BottomType> #t21 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:73:12: Error: The value 'null' can't be returned from a function with return type 'A' because 'A' is not nullable.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+    return null; // Error.
+           ^" in null as{TypeError,ForNonNullableByDefault} self::A;
+  }
+  function local() → FutureOr<self::A> async {
+    if(true) {
+      return let final<BottomType> #t22 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:77:14: Error: The value 'null' can't be returned from an async function with return type 'FutureOr<A>' because 'FutureOr<A>' is not nullable.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+      return null; // Error.
+             ^" in null as{TypeError,ForNonNullableByDefault} self::A;
+    }
+    else {
+      return let final<BottomType> #t23 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:79:18: Error: A value of type 'Future<Null>' can't be returned from an async function with return type 'FutureOr<A>'.
+ - 'Future' is from 'dart:async'.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+      return new Future<Null>.value(null); // Error.
+                 ^" in asy::Future::value<Null>(null) as{TypeError,ForNonNullableByDefault} self::A;
+    }
+  }
 }
 static method main() → dynamic {}
 
diff --git a/pkg/front_end/testcases/nnbd/assignability_error_messages.dart.strong.transformed.expect b/pkg/front_end/testcases/nnbd/assignability_error_messages.dart.strong.transformed.expect
index 6125077..2c1bc3e 100644
--- a/pkg/front_end/testcases/nnbd/assignability_error_messages.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/nnbd/assignability_error_messages.dart.strong.transformed.expect
@@ -2,109 +2,122 @@
 //
 // Problems in library:
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:25:14: Error: The argument type 'B?' can't be assigned to the parameter type 'A' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:27:14: Error: The argument type 'B?' can't be assigned to the parameter type 'A' because 'B?' is nullable and 'A' isn't.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   fooContext(x); // Error.
 //              ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:26:9: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:28:9: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   A a = x; // Error.
 //         ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:27:10: Error: Can't assign spread elements of type 'B?' to collection elements of type 'A' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:29:10: Error: Can't assign spread elements of type 'B?' to collection elements of type 'A' because 'B?' is nullable and 'A' isn't.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   <A>[...l]; // Error.
 //          ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:28:10: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:30:10: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
 //   <A>[...l2]; // Error.
 //          ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:29:13: Error: Can't assign spread entry keys of type 'B?' to map entry keys of type 'A' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:31:13: Error: Can't assign spread entry keys of type 'B?' to map entry keys of type 'A' because 'B?' is nullable and 'A' isn't.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   <A, A>{...m}; // Error.
 //             ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:29:13: Error: Can't assign spread entry values of type 'B?' to map entry values of type 'A' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:31:13: Error: Can't assign spread entry values of type 'B?' to map entry values of type 'A' because 'B?' is nullable and 'A' isn't.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   <A, A>{...m}; // Error.
 //             ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:30:13: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:32:13: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
 //   <A, A>{...m2}; // Error.
 //             ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:31:10: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:33:10: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 // Try changing the type of the variable.
 //   for (A y in l) {} // Error.
 //          ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:32:15: Error: The type 'List<B>?' used in the 'for' loop must implement 'Iterable<dynamic>' because 'List<B>?' is nullable and 'Iterable<dynamic>' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:34:15: Error: The type 'List<B>?' used in the 'for' loop must implement 'Iterable<dynamic>' because 'List<B>?' is nullable and 'Iterable<dynamic>' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'Iterable' is from 'dart:core'.
 //   for (A y in l2) {} // Error.
 //               ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:34:16: Error: Type 'A' of the case expression is not a subtype of type 'B?' of this switch expression.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:36:16: Error: Type 'A' of the case expression is not a subtype of type 'B?' of this switch expression.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //     case const A():
 //                ^
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:33:11: Context: The switch expression is here.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:35:11: Context: The switch expression is here.
 //   switch (x) /*  Error. */ {
 //           ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:39:10: Error: A value of type 'B?' can't be returned from a function with return type 'A' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:43:14: Error: A value of type 'B?' can't be returned from an async function with return type 'FutureOr<A>' because 'B?' is nullable and 'FutureOr<A>' isn't.
+//  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//       return x; // Error.
+//              ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:45:18: Error: A value of type 'Future<B?>' can't be returned from an async function with return type 'FutureOr<A>'.
+//  - 'Future' is from 'dart:async'.
+//  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//       return new Future<B?>.value(x); // Error.
+//                  ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:49:10: Error: A value of type 'B?' can't be returned from a function with return type 'A' because 'B?' is nullable and 'A' isn't.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   return x; // Error.
 //          ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:43:14: Error: The argument type 'List<B?>' can't be assigned to the parameter type 'List<A>' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:53:14: Error: The argument type 'List<B?>' can't be assigned to the parameter type 'List<A>' because 'B?' is nullable and 'A' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   barContext(x); // Error.
 //              ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:44:15: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:54:15: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   List<A> y = x; // Error.
 //               ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:45:16: Error: Can't assign spread elements of type 'List<B?>' to collection elements of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:55:16: Error: Can't assign spread elements of type 'List<B?>' to collection elements of type 'List<A>' because 'B?' is nullable and 'A' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   <List<A>>[...l]; // Error.
 //                ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:46:25: Error: Can't assign spread entry keys of type 'List<B?>' to map entry keys of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:56:25: Error: Can't assign spread entry keys of type 'List<B?>' to map entry keys of type 'List<A>' because 'B?' is nullable and 'A' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   <List<A>, List<A>>{...m}; // Error.
 //                         ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:46:25: Error: Can't assign spread entry values of type 'List<B?>' to map entry values of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:56:25: Error: Can't assign spread entry values of type 'List<B?>' to map entry values of type 'List<A>' because 'B?' is nullable and 'A' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   <List<A>, List<A>>{...m}; // Error.
 //                         ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:47:16: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:57:16: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
@@ -112,19 +125,63 @@
 //   for (List<A> y in l) {} // Error.
 //                ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:48:10: Error: A value of type 'List<B?>' can't be returned from a function with return type 'List<A>' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:58:10: Error: A value of type 'List<B?>' can't be returned from a function with return type 'List<A>' because 'B?' is nullable and 'A' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   return x; // Error.
 //          ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:52:14: Error: The argument type 'num? Function()' can't be assigned to the parameter type 'num Function()' because 'num?' is nullable and 'num' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:62:14: Error: The argument type 'num? Function()' can't be assigned to the parameter type 'num Function()' because 'num?' is nullable and 'num' isn't.
 //   bazContext(c);
 //              ^
 //
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:66:14: Error: The argument type 'Null' can't be assigned to the parameter type 'A' because 'A' is not nullable.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//   fooContext(x); // Error.
+//              ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:67:14: Error: The value 'null' can't be assigned to the parameter type 'A' because 'A' is not nullable.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//   fooContext(null); // Error.
+//              ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:68:10: Error: A value of type 'Null' can't be assigned to a variable of type 'A' because 'A' is not nullable.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//   A a1 = x; // Error.
+//          ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:69:10: Error: The value 'null' can't be assigned to a variable of type 'A' because 'A' is not nullable.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//   A a2 = null; // Error.
+//          ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:71:12: Error: A value of type 'Null' can't be returned from a function with return type 'A' because 'A' is not nullable.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//     return x; // Error.
+//            ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:73:12: Error: The value 'null' can't be returned from a function with return type 'A' because 'A' is not nullable.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//     return null; // Error.
+//            ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:77:14: Error: The value 'null' can't be returned from an async function with return type 'FutureOr<A>' because 'FutureOr<A>' is not nullable.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//       return null; // Error.
+//              ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:79:18: Error: A value of type 'Future<Null>' can't be returned from an async function with return type 'FutureOr<A>'.
+//  - 'Future' is from 'dart:async'.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//       return new Future<Null>.value(null); // Error.
+//                  ^
+//
 import self as self;
 import "dart:core" as core;
+import "dart:async" as asy;
+
+import "dart:async";
 
 class A extends core::Object /*hasConstConstructor*/  {
   const constructor •() → self::A
@@ -146,34 +203,34 @@
 static method barContext(core::List<self::A> x) → void {}
 static method bazContext(() → core::num f) → void {}
 static method foo(self::B? x, core::List<self::B?> l, core::Map<self::B?, self::B?> m, core::List<self::B>? l2, core::Map<self::B, self::B>? m2) → self::A {
-  self::fooContext(let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:25:14: Error: The argument type 'B?' can't be assigned to the parameter type 'A' because 'B?' is nullable and 'A' isn't.
+  self::fooContext(let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:27:14: Error: The argument type 'B?' can't be assigned to the parameter type 'A' because 'B?' is nullable and 'A' isn't.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   fooContext(x); // Error.
              ^" in let self::B? #t2 = x in #t2.==(null) ?{self::A} #t2 as{TypeError,ForNonNullableByDefault} self::A : #t2{self::A});
-  self::A a = let final<BottomType> #t3 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:26:9: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
+  self::A a = let final<BottomType> #t3 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:28:9: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   A a = x; // Error.
         ^" in let self::B? #t4 = x in #t4.==(null) ?{self::A} #t4 as{TypeError,ForNonNullableByDefault} self::A : #t4{self::A};
-  <self::A>[invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:27:10: Error: Can't assign spread elements of type 'B?' to collection elements of type 'A' because 'B?' is nullable and 'A' isn't.
+  <self::A>[invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:29:10: Error: Can't assign spread elements of type 'B?' to collection elements of type 'A' because 'B?' is nullable and 'A' isn't.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   <A>[...l]; // Error.
          ^"];
-  <self::A>[invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:28:10: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+  <self::A>[invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:30:10: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
   <A>[...l2]; // Error.
          ^"];
-  <self::A, self::A>{invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:29:13: Error: Can't assign spread entry keys of type 'B?' to map entry keys of type 'A' because 'B?' is nullable and 'A' isn't.
+  <self::A, self::A>{invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:31:13: Error: Can't assign spread entry keys of type 'B?' to map entry keys of type 'A' because 'B?' is nullable and 'A' isn't.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   <A, A>{...m}; // Error.
-            ^": invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:29:13: Error: Can't assign spread entry values of type 'B?' to map entry values of type 'A' because 'B?' is nullable and 'A' isn't.
+            ^": invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:31:13: Error: Can't assign spread entry values of type 'B?' to map entry values of type 'A' because 'B?' is nullable and 'A' isn't.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   <A, A>{...m}; // Error.
             ^"};
-  <self::A, self::A>{invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:30:13: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+  <self::A, self::A>{invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:32:13: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
   <A, A>{...m2}; // Error.
             ^": null};
   {
@@ -181,7 +238,7 @@
     for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
       final self::B? #t5 = :sync-for-iterator.{core::Iterator::current};
       {
-        self::A y = let final<BottomType> #t6 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:31:10: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
+        self::A y = let final<BottomType> #t6 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:33:10: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 Try changing the type of the variable.
@@ -191,7 +248,7 @@
     }
   }
   {
-    core::Iterator<dynamic> :sync-for-iterator = (let final<BottomType> #t8 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:32:15: Error: The type 'List<B>?' used in the 'for' loop must implement 'Iterable<dynamic>' because 'List<B>?' is nullable and 'Iterable<dynamic>' isn't.
+    core::Iterator<dynamic> :sync-for-iterator = (let final<BottomType> #t8 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:34:15: Error: The type 'List<B>?' used in the 'for' loop must implement 'Iterable<dynamic>' because 'List<B>?' is nullable and 'Iterable<dynamic>' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'Iterable' is from 'dart:core'.
@@ -215,37 +272,81 @@
         break #L1;
       }
   }
-  return let final<BottomType> #t10 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:39:10: Error: A value of type 'B?' can't be returned from a function with return type 'A' because 'B?' is nullable and 'A' isn't.
+  function local() → FutureOr<self::A> /* originally async */ {
+    final asy::_Future<self::A> :async_future = new asy::_Future::•<self::A>();
+    core::bool* :is_sync = false;
+    FutureOr<self::A>? :return_value;
+    dynamic :async_stack_trace;
+    (dynamic) → dynamic :async_op_then;
+    (core::Object, core::StackTrace) → dynamic :async_op_error;
+    core::int :await_jump_var = 0;
+    dynamic :await_ctx_var;
+    function :async_op([dynamic :result, dynamic :exception, dynamic :stack_trace]) → dynamic yielding 
+      try {
+        #L4:
+        {
+          if(true) {
+            :return_value = let final<BottomType> #t10 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:43:14: Error: A value of type 'B?' can't be returned from an async function with return type 'FutureOr<A>' because 'B?' is nullable and 'FutureOr<A>' isn't.
+ - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+      return x; // Error.
+             ^" in let self::B? #t11 = x in #t11.==(null) ?{self::A} #t11 as{TypeError,ForNonNullableByDefault} self::A : #t11{self::A};
+            break #L4;
+          }
+          else {
+            :return_value = let final<BottomType> #t12 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:45:18: Error: A value of type 'Future<B?>' can't be returned from an async function with return type 'FutureOr<A>'.
+ - 'Future' is from 'dart:async'.
+ - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+      return new Future<B?>.value(x); // Error.
+                 ^" in asy::Future::value<self::B?>(x) as{TypeError,ForNonNullableByDefault} self::A;
+            break #L4;
+          }
+        }
+        asy::_completeOnAsyncReturn(:async_future, :return_value, :is_sync);
+        return;
+      }
+      on dynamic catch(dynamic exception, core::StackTrace stack_trace) {
+        asy::_completeOnAsyncError(:async_future, exception, stack_trace, :is_sync);
+      }
+    :async_stack_trace = asy::_asyncStackTraceHelper(:async_op);
+    :async_op_then = asy::_asyncThenWrapperHelper(:async_op);
+    :async_op_error = asy::_asyncErrorWrapperHelper(:async_op);
+    :async_op.call();
+    :is_sync = true;
+    return :async_future;
+  }
+  return let final<BottomType> #t13 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:49:10: Error: A value of type 'B?' can't be returned from a function with return type 'A' because 'B?' is nullable and 'A' isn't.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   return x; // Error.
-         ^" in let self::B? #t11 = x in #t11.==(null) ?{self::A} #t11 as{TypeError,ForNonNullableByDefault} self::A : #t11{self::A};
+         ^" in let self::B? #t14 = x in #t14.==(null) ?{self::A} #t14 as{TypeError,ForNonNullableByDefault} self::A : #t14{self::A};
 }
 static method bar(core::List<self::B?> x, core::List<core::List<self::B?>> l, core::Map<core::List<self::B?>, core::List<self::B?>> m) → core::List<self::A> {
-  self::barContext(let final<BottomType> #t12 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:43:14: Error: The argument type 'List<B?>' can't be assigned to the parameter type 'List<A>' because 'B?' is nullable and 'A' isn't.
+  self::barContext(let final<BottomType> #t15 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:53:14: Error: The argument type 'List<B?>' can't be assigned to the parameter type 'List<A>' because 'B?' is nullable and 'A' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   barContext(x); // Error.
              ^" in x as{TypeError,ForNonNullableByDefault} core::List<self::A>);
-  core::List<self::A> y = let final<BottomType> #t13 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:44:15: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+  core::List<self::A> y = let final<BottomType> #t16 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:54:15: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   List<A> y = x; // Error.
               ^" in x as{TypeError,ForNonNullableByDefault} core::List<self::A>;
-  <core::List<self::A>>[invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:45:16: Error: Can't assign spread elements of type 'List<B?>' to collection elements of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+  <core::List<self::A>>[invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:55:16: Error: Can't assign spread elements of type 'List<B?>' to collection elements of type 'List<A>' because 'B?' is nullable and 'A' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   <List<A>>[...l]; // Error.
                ^"];
-  <core::List<self::A>, core::List<self::A>>{invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:46:25: Error: Can't assign spread entry keys of type 'List<B?>' to map entry keys of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+  <core::List<self::A>, core::List<self::A>>{invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:56:25: Error: Can't assign spread entry keys of type 'List<B?>' to map entry keys of type 'List<A>' because 'B?' is nullable and 'A' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   <List<A>, List<A>>{...m}; // Error.
-                        ^": invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:46:25: Error: Can't assign spread entry values of type 'List<B?>' to map entry values of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+                        ^": invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:56:25: Error: Can't assign spread entry values of type 'List<B?>' to map entry values of type 'List<A>' because 'B?' is nullable and 'A' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
@@ -254,19 +355,19 @@
   {
     core::Iterator<core::List<self::B?>> :sync-for-iterator = l.{core::Iterable::iterator};
     for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
-      final core::List<self::B?> #t14 = :sync-for-iterator.{core::Iterator::current};
+      final core::List<self::B?> #t17 = :sync-for-iterator.{core::Iterator::current};
       {
-        core::List<self::A> y = let final<BottomType> #t15 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:47:16: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+        core::List<self::A> y = let final<BottomType> #t18 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:57:16: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 Try changing the type of the variable.
   for (List<A> y in l) {} // Error.
-               ^" in #t14 as{TypeError,ForNonNullableByDefault} core::List<self::A>;
+               ^" in #t17 as{TypeError,ForNonNullableByDefault} core::List<self::A>;
       }
     }
   }
-  return let final<BottomType> #t16 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:48:10: Error: A value of type 'List<B?>' can't be returned from a function with return type 'List<A>' because 'B?' is nullable and 'A' isn't.
+  return let final<BottomType> #t19 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:58:10: Error: A value of type 'List<B?>' can't be returned from a function with return type 'List<A>' because 'B?' is nullable and 'A' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
@@ -274,12 +375,99 @@
          ^" in x as{TypeError,ForNonNullableByDefault} core::List<self::A>;
 }
 static method baz(self::C c) → void {
-  self::bazContext(let final<BottomType> #t17 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:52:14: Error: The argument type 'num? Function()' can't be assigned to the parameter type 'num Function()' because 'num?' is nullable and 'num' isn't.
+  self::bazContext(let final<BottomType> #t20 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:62:14: Error: The argument type 'num? Function()' can't be assigned to the parameter type 'num Function()' because 'num?' is nullable and 'num' isn't.
   bazContext(c);
-             ^" in (let final self::C #t18 = c in #t18.==(null) ?{() → core::num?} null : #t18.{self::C::call}) as{TypeError,ForNonNullableByDefault} () → core::num);
+             ^" in (let final self::C #t21 = c in #t21.==(null) ?{() → core::num?} null : #t21.{self::C::call}) as{TypeError,ForNonNullableByDefault} () → core::num);
+}
+static method boz(Null x) → self::A {
+  self::fooContext(let final<BottomType> #t22 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:66:14: Error: The argument type 'Null' can't be assigned to the parameter type 'A' because 'A' is not nullable.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+  fooContext(x); // Error.
+             ^" in let Null #t23 = x in #t23.==(null) ?{self::A} #t23 as{TypeError,ForNonNullableByDefault} self::A : #t23{self::A});
+  self::fooContext(let final<BottomType> #t24 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:67:14: Error: The value 'null' can't be assigned to the parameter type 'A' because 'A' is not nullable.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+  fooContext(null); // Error.
+             ^" in let Null #t25 = null in #t25.==(null) ?{self::A} #t25 as{TypeError,ForNonNullableByDefault} self::A : #t25{self::A});
+  self::A a1 = let final<BottomType> #t26 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:68:10: Error: A value of type 'Null' can't be assigned to a variable of type 'A' because 'A' is not nullable.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+  A a1 = x; // Error.
+         ^" in let Null #t27 = x in #t27.==(null) ?{self::A} #t27 as{TypeError,ForNonNullableByDefault} self::A : #t27{self::A};
+  self::A a2 = let final<BottomType> #t28 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:69:10: Error: The value 'null' can't be assigned to a variable of type 'A' because 'A' is not nullable.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+  A a2 = null; // Error.
+         ^" in let Null #t29 = null in #t29.==(null) ?{self::A} #t29 as{TypeError,ForNonNullableByDefault} self::A : #t29{self::A};
+  if(true) {
+    return let final<BottomType> #t30 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:71:12: Error: A value of type 'Null' can't be returned from a function with return type 'A' because 'A' is not nullable.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+    return x; // Error.
+           ^" in let Null #t31 = x in #t31.==(null) ?{self::A} #t31 as{TypeError,ForNonNullableByDefault} self::A : #t31{self::A};
+  }
+  else {
+    return let final<BottomType> #t32 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:73:12: Error: The value 'null' can't be returned from a function with return type 'A' because 'A' is not nullable.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+    return null; // Error.
+           ^" in let Null #t33 = null in #t33.==(null) ?{self::A} #t33 as{TypeError,ForNonNullableByDefault} self::A : #t33{self::A};
+  }
+  function local() → FutureOr<self::A> /* originally async */ {
+    final asy::_Future<self::A> :async_future = new asy::_Future::•<self::A>();
+    core::bool* :is_sync = false;
+    FutureOr<self::A>? :return_value;
+    dynamic :async_stack_trace;
+    (dynamic) → dynamic :async_op_then;
+    (core::Object, core::StackTrace) → dynamic :async_op_error;
+    core::int :await_jump_var = 0;
+    dynamic :await_ctx_var;
+    function :async_op([dynamic :result, dynamic :exception, dynamic :stack_trace]) → dynamic yielding 
+      try {
+        #L5:
+        {
+          if(true) {
+            :return_value = let final<BottomType> #t34 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:77:14: Error: The value 'null' can't be returned from an async function with return type 'FutureOr<A>' because 'FutureOr<A>' is not nullable.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+      return null; // Error.
+             ^" in let Null #t35 = null in #t35.==(null) ?{self::A} #t35 as{TypeError,ForNonNullableByDefault} self::A : #t35{self::A};
+            break #L5;
+          }
+          else {
+            :return_value = let final<BottomType> #t36 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:79:18: Error: A value of type 'Future<Null>' can't be returned from an async function with return type 'FutureOr<A>'.
+ - 'Future' is from 'dart:async'.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+      return new Future<Null>.value(null); // Error.
+                 ^" in asy::Future::value<Null>(null) as{TypeError,ForNonNullableByDefault} self::A;
+            break #L5;
+          }
+        }
+        asy::_completeOnAsyncReturn(:async_future, :return_value, :is_sync);
+        return;
+      }
+      on dynamic catch(dynamic exception, core::StackTrace stack_trace) {
+        asy::_completeOnAsyncError(:async_future, exception, stack_trace, :is_sync);
+      }
+    :async_stack_trace = asy::_asyncStackTraceHelper(:async_op);
+    :async_op_then = asy::_asyncThenWrapperHelper(:async_op);
+    :async_op_error = asy::_asyncErrorWrapperHelper(:async_op);
+    :async_op.call();
+    :is_sync = true;
+    return :async_future;
+  }
 }
 static method main() → dynamic {}
 
 constants  {
   #C1 = self::A {}
 }
+
+Extra constant evaluation status:
+Evaluated: MethodInvocation @ org-dartlang-testcase:///assignability_error_messages.dart:67:14 -> BoolConstant(true)
+Evaluated: VariableGet @ org-dartlang-testcase:///assignability_error_messages.dart:67:14 -> NullConstant(null)
+Evaluated: VariableGet @ org-dartlang-testcase:///assignability_error_messages.dart:67:14 -> NullConstant(null)
+Evaluated: MethodInvocation @ org-dartlang-testcase:///assignability_error_messages.dart:69:10 -> BoolConstant(true)
+Evaluated: VariableGet @ org-dartlang-testcase:///assignability_error_messages.dart:69:10 -> NullConstant(null)
+Evaluated: VariableGet @ org-dartlang-testcase:///assignability_error_messages.dart:69:10 -> NullConstant(null)
+Evaluated: MethodInvocation @ org-dartlang-testcase:///assignability_error_messages.dart:73:12 -> BoolConstant(true)
+Evaluated: VariableGet @ org-dartlang-testcase:///assignability_error_messages.dart:73:12 -> NullConstant(null)
+Evaluated: VariableGet @ org-dartlang-testcase:///assignability_error_messages.dart:73:12 -> NullConstant(null)
+Evaluated: MethodInvocation @ org-dartlang-testcase:///assignability_error_messages.dart:77:14 -> BoolConstant(true)
+Evaluated: VariableGet @ org-dartlang-testcase:///assignability_error_messages.dart:77:14 -> NullConstant(null)
+Evaluated: VariableGet @ org-dartlang-testcase:///assignability_error_messages.dart:77:14 -> NullConstant(null)
+Extra constant evaluation: evaluated: 216, effectively constant: 12
diff --git a/pkg/front_end/testcases/nnbd/assignability_error_messages.dart.textual_outline.expect b/pkg/front_end/testcases/nnbd/assignability_error_messages.dart.textual_outline.expect
index 1447977..77c6443 100644
--- a/pkg/front_end/testcases/nnbd/assignability_error_messages.dart.textual_outline.expect
+++ b/pkg/front_end/testcases/nnbd/assignability_error_messages.dart.textual_outline.expect
@@ -1,3 +1,5 @@
+import 'dart:async';
+
 class A {
   const A();
 }
@@ -14,4 +16,5 @@
 A foo(B? x, List<B?> l, Map<B?, B?> m, List<B>? l2, Map<B, B>? m2) {}
 List<A> bar(List<B?> x, List<List<B?>> l, Map<List<B?>, List<B?>> m) {}
 void baz(C c) {}
+A boz(Null x) {}
 main() {}
diff --git a/pkg/front_end/testcases/nnbd/assignability_error_messages.dart.textual_outline_modelled.expect b/pkg/front_end/testcases/nnbd/assignability_error_messages.dart.textual_outline_modelled.expect
index d624308..ade5e0b 100644
--- a/pkg/front_end/testcases/nnbd/assignability_error_messages.dart.textual_outline_modelled.expect
+++ b/pkg/front_end/testcases/nnbd/assignability_error_messages.dart.textual_outline_modelled.expect
@@ -1,3 +1,6 @@
+import 'dart:async';
+
+A boz(Null x) {}
 A foo(B? x, List<B?> l, Map<B?, B?> m, List<B>? l2, Map<B, B>? m2) {}
 List<A> bar(List<B?> x, List<List<B?>> l, Map<List<B?>, List<B?>> m) {}
 
diff --git a/pkg/front_end/testcases/nnbd/assignability_error_messages.dart.weak.expect b/pkg/front_end/testcases/nnbd/assignability_error_messages.dart.weak.expect
index d89eb7f..a4b4cdc 100644
--- a/pkg/front_end/testcases/nnbd/assignability_error_messages.dart.weak.expect
+++ b/pkg/front_end/testcases/nnbd/assignability_error_messages.dart.weak.expect
@@ -2,109 +2,122 @@
 //
 // Problems in library:
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:25:14: Error: The argument type 'B?' can't be assigned to the parameter type 'A' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:27:14: Error: The argument type 'B?' can't be assigned to the parameter type 'A' because 'B?' is nullable and 'A' isn't.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   fooContext(x); // Error.
 //              ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:26:9: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:28:9: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   A a = x; // Error.
 //         ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:27:10: Error: Can't assign spread elements of type 'B?' to collection elements of type 'A' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:29:10: Error: Can't assign spread elements of type 'B?' to collection elements of type 'A' because 'B?' is nullable and 'A' isn't.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   <A>[...l]; // Error.
 //          ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:28:10: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:30:10: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
 //   <A>[...l2]; // Error.
 //          ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:29:13: Error: Can't assign spread entry keys of type 'B?' to map entry keys of type 'A' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:31:13: Error: Can't assign spread entry keys of type 'B?' to map entry keys of type 'A' because 'B?' is nullable and 'A' isn't.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   <A, A>{...m}; // Error.
 //             ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:29:13: Error: Can't assign spread entry values of type 'B?' to map entry values of type 'A' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:31:13: Error: Can't assign spread entry values of type 'B?' to map entry values of type 'A' because 'B?' is nullable and 'A' isn't.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   <A, A>{...m}; // Error.
 //             ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:30:13: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:32:13: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
 //   <A, A>{...m2}; // Error.
 //             ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:31:10: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:33:10: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 // Try changing the type of the variable.
 //   for (A y in l) {} // Error.
 //          ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:32:15: Error: The type 'List<B>?' used in the 'for' loop must implement 'Iterable<dynamic>' because 'List<B>?' is nullable and 'Iterable<dynamic>' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:34:15: Error: The type 'List<B>?' used in the 'for' loop must implement 'Iterable<dynamic>' because 'List<B>?' is nullable and 'Iterable<dynamic>' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'Iterable' is from 'dart:core'.
 //   for (A y in l2) {} // Error.
 //               ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:34:16: Error: Type 'A' of the case expression is not a subtype of type 'B?' of this switch expression.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:36:16: Error: Type 'A' of the case expression is not a subtype of type 'B?' of this switch expression.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //     case const A():
 //                ^
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:33:11: Context: The switch expression is here.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:35:11: Context: The switch expression is here.
 //   switch (x) /*  Error. */ {
 //           ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:39:10: Error: A value of type 'B?' can't be returned from a function with return type 'A' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:43:14: Error: A value of type 'B?' can't be returned from an async function with return type 'FutureOr<A>' because 'B?' is nullable and 'FutureOr<A>' isn't.
+//  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//       return x; // Error.
+//              ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:45:18: Error: A value of type 'Future<B?>' can't be returned from an async function with return type 'FutureOr<A>'.
+//  - 'Future' is from 'dart:async'.
+//  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//       return new Future<B?>.value(x); // Error.
+//                  ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:49:10: Error: A value of type 'B?' can't be returned from a function with return type 'A' because 'B?' is nullable and 'A' isn't.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   return x; // Error.
 //          ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:43:14: Error: The argument type 'List<B?>' can't be assigned to the parameter type 'List<A>' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:53:14: Error: The argument type 'List<B?>' can't be assigned to the parameter type 'List<A>' because 'B?' is nullable and 'A' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   barContext(x); // Error.
 //              ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:44:15: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:54:15: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   List<A> y = x; // Error.
 //               ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:45:16: Error: Can't assign spread elements of type 'List<B?>' to collection elements of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:55:16: Error: Can't assign spread elements of type 'List<B?>' to collection elements of type 'List<A>' because 'B?' is nullable and 'A' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   <List<A>>[...l]; // Error.
 //                ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:46:25: Error: Can't assign spread entry keys of type 'List<B?>' to map entry keys of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:56:25: Error: Can't assign spread entry keys of type 'List<B?>' to map entry keys of type 'List<A>' because 'B?' is nullable and 'A' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   <List<A>, List<A>>{...m}; // Error.
 //                         ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:46:25: Error: Can't assign spread entry values of type 'List<B?>' to map entry values of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:56:25: Error: Can't assign spread entry values of type 'List<B?>' to map entry values of type 'List<A>' because 'B?' is nullable and 'A' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   <List<A>, List<A>>{...m}; // Error.
 //                         ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:47:16: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:57:16: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
@@ -112,19 +125,63 @@
 //   for (List<A> y in l) {} // Error.
 //                ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:48:10: Error: A value of type 'List<B?>' can't be returned from a function with return type 'List<A>' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:58:10: Error: A value of type 'List<B?>' can't be returned from a function with return type 'List<A>' because 'B?' is nullable and 'A' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   return x; // Error.
 //          ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:52:14: Error: The argument type 'num? Function()' can't be assigned to the parameter type 'num Function()' because 'num?' is nullable and 'num' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:62:14: Error: The argument type 'num? Function()' can't be assigned to the parameter type 'num Function()' because 'num?' is nullable and 'num' isn't.
 //   bazContext(c);
 //              ^
 //
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:66:14: Error: The argument type 'Null' can't be assigned to the parameter type 'A' because 'A' is not nullable.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//   fooContext(x); // Error.
+//              ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:67:14: Error: The value 'null' can't be assigned to the parameter type 'A' because 'A' is not nullable.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//   fooContext(null); // Error.
+//              ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:68:10: Error: A value of type 'Null' can't be assigned to a variable of type 'A' because 'A' is not nullable.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//   A a1 = x; // Error.
+//          ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:69:10: Error: The value 'null' can't be assigned to a variable of type 'A' because 'A' is not nullable.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//   A a2 = null; // Error.
+//          ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:71:12: Error: A value of type 'Null' can't be returned from a function with return type 'A' because 'A' is not nullable.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//     return x; // Error.
+//            ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:73:12: Error: The value 'null' can't be returned from a function with return type 'A' because 'A' is not nullable.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//     return null; // Error.
+//            ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:77:14: Error: The value 'null' can't be returned from an async function with return type 'FutureOr<A>' because 'FutureOr<A>' is not nullable.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//       return null; // Error.
+//              ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:79:18: Error: A value of type 'Future<Null>' can't be returned from an async function with return type 'FutureOr<A>'.
+//  - 'Future' is from 'dart:async'.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//       return new Future<Null>.value(null); // Error.
+//                  ^
+//
 import self as self;
 import "dart:core" as core;
+import "dart:async" as asy;
+
+import "dart:async";
 
 class A extends core::Object /*hasConstConstructor*/  {
   const constructor •() → self::A
@@ -146,45 +203,45 @@
 static method barContext(core::List<self::A> x) → void {}
 static method bazContext(() → core::num f) → void {}
 static method foo(self::B? x, core::List<self::B?> l, core::Map<self::B?, self::B?> m, core::List<self::B>? l2, core::Map<self::B, self::B>? m2) → self::A {
-  self::fooContext(let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:25:14: Error: The argument type 'B?' can't be assigned to the parameter type 'A' because 'B?' is nullable and 'A' isn't.
+  self::fooContext(let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:27:14: Error: The argument type 'B?' can't be assigned to the parameter type 'A' because 'B?' is nullable and 'A' isn't.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   fooContext(x); // Error.
              ^" in x as{TypeError,ForNonNullableByDefault} self::A);
-  self::A a = let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:26:9: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
+  self::A a = let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:28:9: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   A a = x; // Error.
         ^" in x as{TypeError,ForNonNullableByDefault} self::A;
-  <self::A>[invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:27:10: Error: Can't assign spread elements of type 'B?' to collection elements of type 'A' because 'B?' is nullable and 'A' isn't.
+  <self::A>[invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:29:10: Error: Can't assign spread elements of type 'B?' to collection elements of type 'A' because 'B?' is nullable and 'A' isn't.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   <A>[...l]; // Error.
          ^"];
-  <self::A>[invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:28:10: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+  <self::A>[invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:30:10: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
   <A>[...l2]; // Error.
          ^"];
-  <self::A, self::A>{invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:29:13: Error: Can't assign spread entry keys of type 'B?' to map entry keys of type 'A' because 'B?' is nullable and 'A' isn't.
+  <self::A, self::A>{invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:31:13: Error: Can't assign spread entry keys of type 'B?' to map entry keys of type 'A' because 'B?' is nullable and 'A' isn't.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   <A, A>{...m}; // Error.
-            ^": invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:29:13: Error: Can't assign spread entry values of type 'B?' to map entry values of type 'A' because 'B?' is nullable and 'A' isn't.
+            ^": invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:31:13: Error: Can't assign spread entry values of type 'B?' to map entry values of type 'A' because 'B?' is nullable and 'A' isn't.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   <A, A>{...m}; // Error.
             ^"};
-  <self::A, self::A>{invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:30:13: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+  <self::A, self::A>{invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:32:13: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
   <A, A>{...m2}; // Error.
             ^": null};
   for (final self::B? #t3 in l) {
-    self::A y = let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:31:10: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
+    self::A y = let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:33:10: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 Try changing the type of the variable.
   for (A y in l) {} // Error.
          ^" in #t3 as{TypeError,ForNonNullableByDefault} self::A;
   }
-  for (self::A y in let final<BottomType> #t5 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:32:15: Error: The type 'List<B>?' used in the 'for' loop must implement 'Iterable<dynamic>' because 'List<B>?' is nullable and 'Iterable<dynamic>' isn't.
+  for (self::A y in let final<BottomType> #t5 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:34:15: Error: The type 'List<B>?' used in the 'for' loop must implement 'Iterable<dynamic>' because 'List<B>?' is nullable and 'Iterable<dynamic>' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'Iterable' is from 'dart:core'.
@@ -204,52 +261,69 @@
         break #L1;
       }
   }
-  return let final<BottomType> #t6 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:39:10: Error: A value of type 'B?' can't be returned from a function with return type 'A' because 'B?' is nullable and 'A' isn't.
+  function local() → FutureOr<self::A> async {
+    if(true) {
+      return let final<BottomType> #t6 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:43:14: Error: A value of type 'B?' can't be returned from an async function with return type 'FutureOr<A>' because 'B?' is nullable and 'FutureOr<A>' isn't.
+ - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+      return x; // Error.
+             ^" in x as{TypeError,ForNonNullableByDefault} self::A;
+    }
+    else {
+      return let final<BottomType> #t7 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:45:18: Error: A value of type 'Future<B?>' can't be returned from an async function with return type 'FutureOr<A>'.
+ - 'Future' is from 'dart:async'.
+ - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+      return new Future<B?>.value(x); // Error.
+                 ^" in asy::Future::value<self::B?>(x) as{TypeError,ForNonNullableByDefault} self::A;
+    }
+  }
+  return let final<BottomType> #t8 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:49:10: Error: A value of type 'B?' can't be returned from a function with return type 'A' because 'B?' is nullable and 'A' isn't.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   return x; // Error.
          ^" in x as{TypeError,ForNonNullableByDefault} self::A;
 }
 static method bar(core::List<self::B?> x, core::List<core::List<self::B?>> l, core::Map<core::List<self::B?>, core::List<self::B?>> m) → core::List<self::A> {
-  self::barContext(let final<BottomType> #t7 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:43:14: Error: The argument type 'List<B?>' can't be assigned to the parameter type 'List<A>' because 'B?' is nullable and 'A' isn't.
+  self::barContext(let final<BottomType> #t9 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:53:14: Error: The argument type 'List<B?>' can't be assigned to the parameter type 'List<A>' because 'B?' is nullable and 'A' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   barContext(x); // Error.
              ^" in x as{TypeError,ForNonNullableByDefault} core::List<self::A>);
-  core::List<self::A> y = let final<BottomType> #t8 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:44:15: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+  core::List<self::A> y = let final<BottomType> #t10 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:54:15: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   List<A> y = x; // Error.
               ^" in x as{TypeError,ForNonNullableByDefault} core::List<self::A>;
-  <core::List<self::A>>[invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:45:16: Error: Can't assign spread elements of type 'List<B?>' to collection elements of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+  <core::List<self::A>>[invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:55:16: Error: Can't assign spread elements of type 'List<B?>' to collection elements of type 'List<A>' because 'B?' is nullable and 'A' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   <List<A>>[...l]; // Error.
                ^"];
-  <core::List<self::A>, core::List<self::A>>{invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:46:25: Error: Can't assign spread entry keys of type 'List<B?>' to map entry keys of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+  <core::List<self::A>, core::List<self::A>>{invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:56:25: Error: Can't assign spread entry keys of type 'List<B?>' to map entry keys of type 'List<A>' because 'B?' is nullable and 'A' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   <List<A>, List<A>>{...m}; // Error.
-                        ^": invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:46:25: Error: Can't assign spread entry values of type 'List<B?>' to map entry values of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+                        ^": invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:56:25: Error: Can't assign spread entry values of type 'List<B?>' to map entry values of type 'List<A>' because 'B?' is nullable and 'A' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   <List<A>, List<A>>{...m}; // Error.
                         ^"};
-  for (final core::List<self::B?> #t9 in l) {
-    core::List<self::A> y = let final<BottomType> #t10 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:47:16: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+  for (final core::List<self::B?> #t11 in l) {
+    core::List<self::A> y = let final<BottomType> #t12 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:57:16: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 Try changing the type of the variable.
   for (List<A> y in l) {} // Error.
-               ^" in #t9 as{TypeError,ForNonNullableByDefault} core::List<self::A>;
+               ^" in #t11 as{TypeError,ForNonNullableByDefault} core::List<self::A>;
   }
-  return let final<BottomType> #t11 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:48:10: Error: A value of type 'List<B?>' can't be returned from a function with return type 'List<A>' because 'B?' is nullable and 'A' isn't.
+  return let final<BottomType> #t13 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:58:10: Error: A value of type 'List<B?>' can't be returned from a function with return type 'List<A>' because 'B?' is nullable and 'A' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
@@ -257,9 +331,54 @@
          ^" in x as{TypeError,ForNonNullableByDefault} core::List<self::A>;
 }
 static method baz(self::C c) → void {
-  self::bazContext(let final<BottomType> #t12 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:52:14: Error: The argument type 'num? Function()' can't be assigned to the parameter type 'num Function()' because 'num?' is nullable and 'num' isn't.
+  self::bazContext(let final<BottomType> #t14 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:62:14: Error: The argument type 'num? Function()' can't be assigned to the parameter type 'num Function()' because 'num?' is nullable and 'num' isn't.
   bazContext(c);
-             ^" in (let final self::C #t13 = c in #t13.==(null) ?{() → core::num?} null : #t13.{self::C::call}) as{TypeError,ForNonNullableByDefault} () → core::num);
+             ^" in (let final self::C #t15 = c in #t15.==(null) ?{() → core::num?} null : #t15.{self::C::call}) as{TypeError,ForNonNullableByDefault} () → core::num);
+}
+static method boz(Null x) → self::A {
+  self::fooContext(let final<BottomType> #t16 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:66:14: Error: The argument type 'Null' can't be assigned to the parameter type 'A' because 'A' is not nullable.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+  fooContext(x); // Error.
+             ^" in x as{TypeError,ForNonNullableByDefault} self::A);
+  self::fooContext(let final<BottomType> #t17 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:67:14: Error: The value 'null' can't be assigned to the parameter type 'A' because 'A' is not nullable.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+  fooContext(null); // Error.
+             ^" in null as{TypeError,ForNonNullableByDefault} self::A);
+  self::A a1 = let final<BottomType> #t18 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:68:10: Error: A value of type 'Null' can't be assigned to a variable of type 'A' because 'A' is not nullable.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+  A a1 = x; // Error.
+         ^" in x as{TypeError,ForNonNullableByDefault} self::A;
+  self::A a2 = let final<BottomType> #t19 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:69:10: Error: The value 'null' can't be assigned to a variable of type 'A' because 'A' is not nullable.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+  A a2 = null; // Error.
+         ^" in null as{TypeError,ForNonNullableByDefault} self::A;
+  if(true) {
+    return let final<BottomType> #t20 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:71:12: Error: A value of type 'Null' can't be returned from a function with return type 'A' because 'A' is not nullable.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+    return x; // Error.
+           ^" in x as{TypeError,ForNonNullableByDefault} self::A;
+  }
+  else {
+    return let final<BottomType> #t21 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:73:12: Error: The value 'null' can't be returned from a function with return type 'A' because 'A' is not nullable.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+    return null; // Error.
+           ^" in null as{TypeError,ForNonNullableByDefault} self::A;
+  }
+  function local() → FutureOr<self::A> async {
+    if(true) {
+      return let final<BottomType> #t22 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:77:14: Error: The value 'null' can't be returned from an async function with return type 'FutureOr<A>' because 'FutureOr<A>' is not nullable.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+      return null; // Error.
+             ^" in null as{TypeError,ForNonNullableByDefault} self::A;
+    }
+    else {
+      return let final<BottomType> #t23 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:79:18: Error: A value of type 'Future<Null>' can't be returned from an async function with return type 'FutureOr<A>'.
+ - 'Future' is from 'dart:async'.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+      return new Future<Null>.value(null); // Error.
+                 ^" in asy::Future::value<Null>(null) as{TypeError,ForNonNullableByDefault} self::A;
+    }
+  }
 }
 static method main() → dynamic {}
 
diff --git a/pkg/front_end/testcases/nnbd/assignability_error_messages.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd/assignability_error_messages.dart.weak.transformed.expect
index 56534e7..a63f3a4 100644
--- a/pkg/front_end/testcases/nnbd/assignability_error_messages.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/nnbd/assignability_error_messages.dart.weak.transformed.expect
@@ -2,109 +2,122 @@
 //
 // Problems in library:
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:25:14: Error: The argument type 'B?' can't be assigned to the parameter type 'A' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:27:14: Error: The argument type 'B?' can't be assigned to the parameter type 'A' because 'B?' is nullable and 'A' isn't.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   fooContext(x); // Error.
 //              ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:26:9: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:28:9: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   A a = x; // Error.
 //         ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:27:10: Error: Can't assign spread elements of type 'B?' to collection elements of type 'A' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:29:10: Error: Can't assign spread elements of type 'B?' to collection elements of type 'A' because 'B?' is nullable and 'A' isn't.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   <A>[...l]; // Error.
 //          ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:28:10: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:30:10: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
 //   <A>[...l2]; // Error.
 //          ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:29:13: Error: Can't assign spread entry keys of type 'B?' to map entry keys of type 'A' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:31:13: Error: Can't assign spread entry keys of type 'B?' to map entry keys of type 'A' because 'B?' is nullable and 'A' isn't.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   <A, A>{...m}; // Error.
 //             ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:29:13: Error: Can't assign spread entry values of type 'B?' to map entry values of type 'A' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:31:13: Error: Can't assign spread entry values of type 'B?' to map entry values of type 'A' because 'B?' is nullable and 'A' isn't.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   <A, A>{...m}; // Error.
 //             ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:30:13: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:32:13: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
 //   <A, A>{...m2}; // Error.
 //             ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:31:10: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:33:10: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 // Try changing the type of the variable.
 //   for (A y in l) {} // Error.
 //          ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:32:15: Error: The type 'List<B>?' used in the 'for' loop must implement 'Iterable<dynamic>' because 'List<B>?' is nullable and 'Iterable<dynamic>' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:34:15: Error: The type 'List<B>?' used in the 'for' loop must implement 'Iterable<dynamic>' because 'List<B>?' is nullable and 'Iterable<dynamic>' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'Iterable' is from 'dart:core'.
 //   for (A y in l2) {} // Error.
 //               ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:34:16: Error: Type 'A' of the case expression is not a subtype of type 'B?' of this switch expression.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:36:16: Error: Type 'A' of the case expression is not a subtype of type 'B?' of this switch expression.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //     case const A():
 //                ^
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:33:11: Context: The switch expression is here.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:35:11: Context: The switch expression is here.
 //   switch (x) /*  Error. */ {
 //           ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:39:10: Error: A value of type 'B?' can't be returned from a function with return type 'A' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:43:14: Error: A value of type 'B?' can't be returned from an async function with return type 'FutureOr<A>' because 'B?' is nullable and 'FutureOr<A>' isn't.
+//  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//       return x; // Error.
+//              ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:45:18: Error: A value of type 'Future<B?>' can't be returned from an async function with return type 'FutureOr<A>'.
+//  - 'Future' is from 'dart:async'.
+//  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//       return new Future<B?>.value(x); // Error.
+//                  ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:49:10: Error: A value of type 'B?' can't be returned from a function with return type 'A' because 'B?' is nullable and 'A' isn't.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   return x; // Error.
 //          ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:43:14: Error: The argument type 'List<B?>' can't be assigned to the parameter type 'List<A>' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:53:14: Error: The argument type 'List<B?>' can't be assigned to the parameter type 'List<A>' because 'B?' is nullable and 'A' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   barContext(x); // Error.
 //              ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:44:15: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:54:15: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   List<A> y = x; // Error.
 //               ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:45:16: Error: Can't assign spread elements of type 'List<B?>' to collection elements of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:55:16: Error: Can't assign spread elements of type 'List<B?>' to collection elements of type 'List<A>' because 'B?' is nullable and 'A' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   <List<A>>[...l]; // Error.
 //                ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:46:25: Error: Can't assign spread entry keys of type 'List<B?>' to map entry keys of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:56:25: Error: Can't assign spread entry keys of type 'List<B?>' to map entry keys of type 'List<A>' because 'B?' is nullable and 'A' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   <List<A>, List<A>>{...m}; // Error.
 //                         ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:46:25: Error: Can't assign spread entry values of type 'List<B?>' to map entry values of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:56:25: Error: Can't assign spread entry values of type 'List<B?>' to map entry values of type 'List<A>' because 'B?' is nullable and 'A' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   <List<A>, List<A>>{...m}; // Error.
 //                         ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:47:16: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:57:16: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
@@ -112,19 +125,63 @@
 //   for (List<A> y in l) {} // Error.
 //                ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:48:10: Error: A value of type 'List<B?>' can't be returned from a function with return type 'List<A>' because 'B?' is nullable and 'A' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:58:10: Error: A value of type 'List<B?>' can't be returned from a function with return type 'List<A>' because 'B?' is nullable and 'A' isn't.
 //  - 'List' is from 'dart:core'.
 //  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 //   return x; // Error.
 //          ^
 //
-// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:52:14: Error: The argument type 'num? Function()' can't be assigned to the parameter type 'num Function()' because 'num?' is nullable and 'num' isn't.
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:62:14: Error: The argument type 'num? Function()' can't be assigned to the parameter type 'num Function()' because 'num?' is nullable and 'num' isn't.
 //   bazContext(c);
 //              ^
 //
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:66:14: Error: The argument type 'Null' can't be assigned to the parameter type 'A' because 'A' is not nullable.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//   fooContext(x); // Error.
+//              ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:67:14: Error: The value 'null' can't be assigned to the parameter type 'A' because 'A' is not nullable.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//   fooContext(null); // Error.
+//              ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:68:10: Error: A value of type 'Null' can't be assigned to a variable of type 'A' because 'A' is not nullable.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//   A a1 = x; // Error.
+//          ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:69:10: Error: The value 'null' can't be assigned to a variable of type 'A' because 'A' is not nullable.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//   A a2 = null; // Error.
+//          ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:71:12: Error: A value of type 'Null' can't be returned from a function with return type 'A' because 'A' is not nullable.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//     return x; // Error.
+//            ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:73:12: Error: The value 'null' can't be returned from a function with return type 'A' because 'A' is not nullable.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//     return null; // Error.
+//            ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:77:14: Error: The value 'null' can't be returned from an async function with return type 'FutureOr<A>' because 'FutureOr<A>' is not nullable.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//       return null; // Error.
+//              ^
+//
+// pkg/front_end/testcases/nnbd/assignability_error_messages.dart:79:18: Error: A value of type 'Future<Null>' can't be returned from an async function with return type 'FutureOr<A>'.
+//  - 'Future' is from 'dart:async'.
+//  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+//       return new Future<Null>.value(null); // Error.
+//                  ^
+//
 import self as self;
 import "dart:core" as core;
+import "dart:async" as asy;
+
+import "dart:async";
 
 class A extends core::Object /*hasConstConstructor*/  {
   const constructor •() → self::A
@@ -146,34 +203,34 @@
 static method barContext(core::List<self::A> x) → void {}
 static method bazContext(() → core::num f) → void {}
 static method foo(self::B? x, core::List<self::B?> l, core::Map<self::B?, self::B?> m, core::List<self::B>? l2, core::Map<self::B, self::B>? m2) → self::A {
-  self::fooContext(let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:25:14: Error: The argument type 'B?' can't be assigned to the parameter type 'A' because 'B?' is nullable and 'A' isn't.
+  self::fooContext(let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:27:14: Error: The argument type 'B?' can't be assigned to the parameter type 'A' because 'B?' is nullable and 'A' isn't.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   fooContext(x); // Error.
              ^" in x);
-  self::A a = let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:26:9: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
+  self::A a = let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:28:9: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   A a = x; // Error.
         ^" in x;
-  <self::A>[invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:27:10: Error: Can't assign spread elements of type 'B?' to collection elements of type 'A' because 'B?' is nullable and 'A' isn't.
+  <self::A>[invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:29:10: Error: Can't assign spread elements of type 'B?' to collection elements of type 'A' because 'B?' is nullable and 'A' isn't.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   <A>[...l]; // Error.
          ^"];
-  <self::A>[invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:28:10: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+  <self::A>[invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:30:10: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
   <A>[...l2]; // Error.
          ^"];
-  <self::A, self::A>{invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:29:13: Error: Can't assign spread entry keys of type 'B?' to map entry keys of type 'A' because 'B?' is nullable and 'A' isn't.
+  <self::A, self::A>{invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:31:13: Error: Can't assign spread entry keys of type 'B?' to map entry keys of type 'A' because 'B?' is nullable and 'A' isn't.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   <A, A>{...m}; // Error.
-            ^": invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:29:13: Error: Can't assign spread entry values of type 'B?' to map entry values of type 'A' because 'B?' is nullable and 'A' isn't.
+            ^": invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:31:13: Error: Can't assign spread entry values of type 'B?' to map entry values of type 'A' because 'B?' is nullable and 'A' isn't.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   <A, A>{...m}; // Error.
             ^"};
-  <self::A, self::A>{invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:30:13: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+  <self::A, self::A>{invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:32:13: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
   <A, A>{...m2}; // Error.
             ^": null};
   {
@@ -181,7 +238,7 @@
     for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
       final self::B? #t3 = :sync-for-iterator.{core::Iterator::current};
       {
-        self::A y = let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:31:10: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
+        self::A y = let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:33:10: Error: A value of type 'B?' can't be assigned to a variable of type 'A' because 'B?' is nullable and 'A' isn't.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 Try changing the type of the variable.
@@ -191,7 +248,7 @@
     }
   }
   {
-    core::Iterator<dynamic> :sync-for-iterator = (let final<BottomType> #t5 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:32:15: Error: The type 'List<B>?' used in the 'for' loop must implement 'Iterable<dynamic>' because 'List<B>?' is nullable and 'Iterable<dynamic>' isn't.
+    core::Iterator<dynamic> :sync-for-iterator = (let final<BottomType> #t5 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:34:15: Error: The type 'List<B>?' used in the 'for' loop must implement 'Iterable<dynamic>' because 'List<B>?' is nullable and 'Iterable<dynamic>' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'Iterable' is from 'dart:core'.
@@ -215,37 +272,81 @@
         break #L1;
       }
   }
-  return let final<BottomType> #t6 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:39:10: Error: A value of type 'B?' can't be returned from a function with return type 'A' because 'B?' is nullable and 'A' isn't.
+  function local() → FutureOr<self::A> /* originally async */ {
+    final asy::_Future<self::A> :async_future = new asy::_Future::•<self::A>();
+    core::bool* :is_sync = false;
+    FutureOr<self::A>? :return_value;
+    dynamic :async_stack_trace;
+    (dynamic) → dynamic :async_op_then;
+    (core::Object, core::StackTrace) → dynamic :async_op_error;
+    core::int :await_jump_var = 0;
+    dynamic :await_ctx_var;
+    function :async_op([dynamic :result, dynamic :exception, dynamic :stack_trace]) → dynamic yielding 
+      try {
+        #L4:
+        {
+          if(true) {
+            :return_value = let final<BottomType> #t6 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:43:14: Error: A value of type 'B?' can't be returned from an async function with return type 'FutureOr<A>' because 'B?' is nullable and 'FutureOr<A>' isn't.
+ - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+      return x; // Error.
+             ^" in x;
+            break #L4;
+          }
+          else {
+            :return_value = let final<BottomType> #t7 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:45:18: Error: A value of type 'Future<B?>' can't be returned from an async function with return type 'FutureOr<A>'.
+ - 'Future' is from 'dart:async'.
+ - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+      return new Future<B?>.value(x); // Error.
+                 ^" in asy::Future::value<self::B?>(x) as{TypeError,ForNonNullableByDefault} self::A;
+            break #L4;
+          }
+        }
+        asy::_completeOnAsyncReturn(:async_future, :return_value, :is_sync);
+        return;
+      }
+      on dynamic catch(dynamic exception, core::StackTrace stack_trace) {
+        asy::_completeOnAsyncError(:async_future, exception, stack_trace, :is_sync);
+      }
+    :async_stack_trace = asy::_asyncStackTraceHelper(:async_op);
+    :async_op_then = asy::_asyncThenWrapperHelper(:async_op);
+    :async_op_error = asy::_asyncErrorWrapperHelper(:async_op);
+    :async_op.call();
+    :is_sync = true;
+    return :async_future;
+  }
+  return let final<BottomType> #t8 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:49:10: Error: A value of type 'B?' can't be returned from a function with return type 'A' because 'B?' is nullable and 'A' isn't.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   return x; // Error.
          ^" in x;
 }
 static method bar(core::List<self::B?> x, core::List<core::List<self::B?>> l, core::Map<core::List<self::B?>, core::List<self::B?>> m) → core::List<self::A> {
-  self::barContext(let final<BottomType> #t7 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:43:14: Error: The argument type 'List<B?>' can't be assigned to the parameter type 'List<A>' because 'B?' is nullable and 'A' isn't.
+  self::barContext(let final<BottomType> #t9 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:53:14: Error: The argument type 'List<B?>' can't be assigned to the parameter type 'List<A>' because 'B?' is nullable and 'A' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   barContext(x); // Error.
              ^" in x);
-  core::List<self::A> y = let final<BottomType> #t8 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:44:15: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+  core::List<self::A> y = let final<BottomType> #t10 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:54:15: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   List<A> y = x; // Error.
               ^" in x;
-  <core::List<self::A>>[invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:45:16: Error: Can't assign spread elements of type 'List<B?>' to collection elements of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+  <core::List<self::A>>[invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:55:16: Error: Can't assign spread elements of type 'List<B?>' to collection elements of type 'List<A>' because 'B?' is nullable and 'A' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   <List<A>>[...l]; // Error.
                ^"];
-  <core::List<self::A>, core::List<self::A>>{invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:46:25: Error: Can't assign spread entry keys of type 'List<B?>' to map entry keys of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+  <core::List<self::A>, core::List<self::A>>{invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:56:25: Error: Can't assign spread entry keys of type 'List<B?>' to map entry keys of type 'List<A>' because 'B?' is nullable and 'A' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
   <List<A>, List<A>>{...m}; // Error.
-                        ^": invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:46:25: Error: Can't assign spread entry values of type 'List<B?>' to map entry values of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+                        ^": invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:56:25: Error: Can't assign spread entry values of type 'List<B?>' to map entry values of type 'List<A>' because 'B?' is nullable and 'A' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
@@ -254,19 +355,19 @@
   {
     core::Iterator<core::List<self::B?>> :sync-for-iterator = l.{core::Iterable::iterator};
     for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
-      final core::List<self::B?> #t9 = :sync-for-iterator.{core::Iterator::current};
+      final core::List<self::B?> #t11 = :sync-for-iterator.{core::Iterator::current};
       {
-        core::List<self::A> y = let final<BottomType> #t10 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:47:16: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
+        core::List<self::A> y = let final<BottomType> #t12 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:57:16: Error: A value of type 'List<B?>' can't be assigned to a variable of type 'List<A>' because 'B?' is nullable and 'A' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
 Try changing the type of the variable.
   for (List<A> y in l) {} // Error.
-               ^" in #t9;
+               ^" in #t11;
       }
     }
   }
-  return let final<BottomType> #t11 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:48:10: Error: A value of type 'List<B?>' can't be returned from a function with return type 'List<A>' because 'B?' is nullable and 'A' isn't.
+  return let final<BottomType> #t13 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:58:10: Error: A value of type 'List<B?>' can't be returned from a function with return type 'List<A>' because 'B?' is nullable and 'A' isn't.
  - 'List' is from 'dart:core'.
  - 'B' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
  - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
@@ -274,9 +375,81 @@
          ^" in x;
 }
 static method baz(self::C c) → void {
-  self::bazContext(let final<BottomType> #t12 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:52:14: Error: The argument type 'num? Function()' can't be assigned to the parameter type 'num Function()' because 'num?' is nullable and 'num' isn't.
+  self::bazContext(let final<BottomType> #t14 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:62:14: Error: The argument type 'num? Function()' can't be assigned to the parameter type 'num Function()' because 'num?' is nullable and 'num' isn't.
   bazContext(c);
-             ^" in let final self::C #t13 = c in #t13.==(null) ?{() → core::num?} null : #t13.{self::C::call});
+             ^" in let final self::C #t15 = c in #t15.==(null) ?{() → core::num?} null : #t15.{self::C::call});
+}
+static method boz(Null x) → self::A {
+  self::fooContext(let final<BottomType> #t16 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:66:14: Error: The argument type 'Null' can't be assigned to the parameter type 'A' because 'A' is not nullable.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+  fooContext(x); // Error.
+             ^" in x);
+  self::fooContext(let final<BottomType> #t17 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:67:14: Error: The value 'null' can't be assigned to the parameter type 'A' because 'A' is not nullable.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+  fooContext(null); // Error.
+             ^" in null);
+  self::A a1 = let final<BottomType> #t18 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:68:10: Error: A value of type 'Null' can't be assigned to a variable of type 'A' because 'A' is not nullable.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+  A a1 = x; // Error.
+         ^" in x;
+  self::A a2 = let final<BottomType> #t19 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:69:10: Error: The value 'null' can't be assigned to a variable of type 'A' because 'A' is not nullable.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+  A a2 = null; // Error.
+         ^" in null;
+  if(true) {
+    return let final<BottomType> #t20 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:71:12: Error: A value of type 'Null' can't be returned from a function with return type 'A' because 'A' is not nullable.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+    return x; // Error.
+           ^" in x;
+  }
+  else {
+    return let final<BottomType> #t21 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:73:12: Error: The value 'null' can't be returned from a function with return type 'A' because 'A' is not nullable.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+    return null; // Error.
+           ^" in null;
+  }
+  function local() → FutureOr<self::A> /* originally async */ {
+    final asy::_Future<self::A> :async_future = new asy::_Future::•<self::A>();
+    core::bool* :is_sync = false;
+    FutureOr<self::A>? :return_value;
+    dynamic :async_stack_trace;
+    (dynamic) → dynamic :async_op_then;
+    (core::Object, core::StackTrace) → dynamic :async_op_error;
+    core::int :await_jump_var = 0;
+    dynamic :await_ctx_var;
+    function :async_op([dynamic :result, dynamic :exception, dynamic :stack_trace]) → dynamic yielding 
+      try {
+        #L5:
+        {
+          if(true) {
+            :return_value = let final<BottomType> #t22 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:77:14: Error: The value 'null' can't be returned from an async function with return type 'FutureOr<A>' because 'FutureOr<A>' is not nullable.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+      return null; // Error.
+             ^" in null;
+            break #L5;
+          }
+          else {
+            :return_value = let final<BottomType> #t23 = invalid-expression "pkg/front_end/testcases/nnbd/assignability_error_messages.dart:79:18: Error: A value of type 'Future<Null>' can't be returned from an async function with return type 'FutureOr<A>'.
+ - 'Future' is from 'dart:async'.
+ - 'A' is from 'pkg/front_end/testcases/nnbd/assignability_error_messages.dart'.
+      return new Future<Null>.value(null); // Error.
+                 ^" in asy::Future::value<Null>(null) as{TypeError,ForNonNullableByDefault} self::A;
+            break #L5;
+          }
+        }
+        asy::_completeOnAsyncReturn(:async_future, :return_value, :is_sync);
+        return;
+      }
+      on dynamic catch(dynamic exception, core::StackTrace stack_trace) {
+        asy::_completeOnAsyncError(:async_future, exception, stack_trace, :is_sync);
+      }
+    :async_stack_trace = asy::_asyncStackTraceHelper(:async_op);
+    :async_op_then = asy::_asyncThenWrapperHelper(:async_op);
+    :async_op_error = asy::_asyncErrorWrapperHelper(:async_op);
+    :async_op.call();
+    :is_sync = true;
+    return :async_future;
+  }
 }
 static method main() → dynamic {}
 
diff --git a/pkg/front_end/testcases/nnbd/combined_required.dart b/pkg/front_end/testcases/nnbd/combined_required.dart
new file mode 100644
index 0000000..9584091
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/combined_required.dart
@@ -0,0 +1,18 @@
+class A {
+  void method1({required int a}) {}
+  void method2({int? a, required int b}) {}
+}
+
+class B {
+  void method1({required covariant int a}) {}
+  void method2({covariant int? a, required int b}) {}
+}
+
+class C extends A implements B {}
+
+class D extends C {
+  void method1({required covariant int a}) {}
+  void method2({covariant int? a, required int b}) {}
+}
+
+main() {}
diff --git a/pkg/front_end/testcases/nnbd/combined_required.dart.outline.expect b/pkg/front_end/testcases/nnbd/combined_required.dart.outline.expect
new file mode 100644
index 0000000..f39bdf2
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/combined_required.dart.outline.expect
@@ -0,0 +1,38 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+class A extends core::Object {
+  synthetic constructor •() → self::A
+    ;
+  method method1({required core::int a}) → void
+    ;
+  method method2({core::int? a, required core::int b}) → void
+    ;
+}
+class B extends core::Object {
+  synthetic constructor •() → self::B
+    ;
+  method method1({required covariant core::int a}) → void
+    ;
+  method method2({covariant core::int? a, required core::int b}) → void
+    ;
+}
+class C extends self::A implements self::B {
+  synthetic constructor •() → self::C
+    ;
+  forwarding-stub method method1({required covariant core::int a}) → void
+    return super.{self::A::method1}(a: a);
+  forwarding-stub method method2({covariant core::int? a, required core::int b}) → void
+    return super.{self::A::method2}(a: a, b: b);
+}
+class D extends self::C {
+  synthetic constructor •() → self::D
+    ;
+  method method1({required covariant core::int a}) → void
+    ;
+  method method2({covariant core::int? a, required core::int b}) → void
+    ;
+}
+static method main() → dynamic
+  ;
diff --git a/pkg/front_end/testcases/nnbd/combined_required.dart.strong.expect b/pkg/front_end/testcases/nnbd/combined_required.dart.strong.expect
new file mode 100644
index 0000000..34958ef
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/combined_required.dart.strong.expect
@@ -0,0 +1,39 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+class A extends core::Object {
+  synthetic constructor •() → self::A
+    : super core::Object::•()
+    ;
+  method method1({required core::int a = #C1}) → void {}
+  method method2({core::int? a = #C1, required core::int b = #C1}) → void {}
+}
+class B extends core::Object {
+  synthetic constructor •() → self::B
+    : super core::Object::•()
+    ;
+  method method1({required covariant core::int a = #C1}) → void {}
+  method method2({covariant core::int? a = #C1, required core::int b = #C1}) → void {}
+}
+class C extends self::A implements self::B {
+  synthetic constructor •() → self::C
+    : super self::A::•()
+    ;
+  forwarding-stub method method1({required covariant core::int a = #C1}) → void
+    return super.{self::A::method1}(a: a);
+  forwarding-stub method method2({covariant core::int? a = #C1, required core::int b = #C1}) → void
+    return super.{self::A::method2}(a: a, b: b);
+}
+class D extends self::C {
+  synthetic constructor •() → self::D
+    : super self::C::•()
+    ;
+  method method1({required covariant core::int a = #C1}) → void {}
+  method method2({covariant core::int? a = #C1, required core::int b = #C1}) → void {}
+}
+static method main() → dynamic {}
+
+constants  {
+  #C1 = null
+}
diff --git a/pkg/front_end/testcases/nnbd/combined_required.dart.strong.transformed.expect b/pkg/front_end/testcases/nnbd/combined_required.dart.strong.transformed.expect
new file mode 100644
index 0000000..34958ef
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/combined_required.dart.strong.transformed.expect
@@ -0,0 +1,39 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+class A extends core::Object {
+  synthetic constructor •() → self::A
+    : super core::Object::•()
+    ;
+  method method1({required core::int a = #C1}) → void {}
+  method method2({core::int? a = #C1, required core::int b = #C1}) → void {}
+}
+class B extends core::Object {
+  synthetic constructor •() → self::B
+    : super core::Object::•()
+    ;
+  method method1({required covariant core::int a = #C1}) → void {}
+  method method2({covariant core::int? a = #C1, required core::int b = #C1}) → void {}
+}
+class C extends self::A implements self::B {
+  synthetic constructor •() → self::C
+    : super self::A::•()
+    ;
+  forwarding-stub method method1({required covariant core::int a = #C1}) → void
+    return super.{self::A::method1}(a: a);
+  forwarding-stub method method2({covariant core::int? a = #C1, required core::int b = #C1}) → void
+    return super.{self::A::method2}(a: a, b: b);
+}
+class D extends self::C {
+  synthetic constructor •() → self::D
+    : super self::C::•()
+    ;
+  method method1({required covariant core::int a = #C1}) → void {}
+  method method2({covariant core::int? a = #C1, required core::int b = #C1}) → void {}
+}
+static method main() → dynamic {}
+
+constants  {
+  #C1 = null
+}
diff --git a/pkg/front_end/testcases/nnbd/combined_required.dart.textual_outline.expect b/pkg/front_end/testcases/nnbd/combined_required.dart.textual_outline.expect
new file mode 100644
index 0000000..9584091
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/combined_required.dart.textual_outline.expect
@@ -0,0 +1,18 @@
+class A {
+  void method1({required int a}) {}
+  void method2({int? a, required int b}) {}
+}
+
+class B {
+  void method1({required covariant int a}) {}
+  void method2({covariant int? a, required int b}) {}
+}
+
+class C extends A implements B {}
+
+class D extends C {
+  void method1({required covariant int a}) {}
+  void method2({covariant int? a, required int b}) {}
+}
+
+main() {}
diff --git a/pkg/front_end/testcases/nnbd/combined_required.dart.textual_outline_modelled.expect b/pkg/front_end/testcases/nnbd/combined_required.dart.textual_outline_modelled.expect
new file mode 100644
index 0000000..9584091
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/combined_required.dart.textual_outline_modelled.expect
@@ -0,0 +1,18 @@
+class A {
+  void method1({required int a}) {}
+  void method2({int? a, required int b}) {}
+}
+
+class B {
+  void method1({required covariant int a}) {}
+  void method2({covariant int? a, required int b}) {}
+}
+
+class C extends A implements B {}
+
+class D extends C {
+  void method1({required covariant int a}) {}
+  void method2({covariant int? a, required int b}) {}
+}
+
+main() {}
diff --git a/pkg/front_end/testcases/nnbd/combined_required.dart.weak.expect b/pkg/front_end/testcases/nnbd/combined_required.dart.weak.expect
new file mode 100644
index 0000000..34958ef
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/combined_required.dart.weak.expect
@@ -0,0 +1,39 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+class A extends core::Object {
+  synthetic constructor •() → self::A
+    : super core::Object::•()
+    ;
+  method method1({required core::int a = #C1}) → void {}
+  method method2({core::int? a = #C1, required core::int b = #C1}) → void {}
+}
+class B extends core::Object {
+  synthetic constructor •() → self::B
+    : super core::Object::•()
+    ;
+  method method1({required covariant core::int a = #C1}) → void {}
+  method method2({covariant core::int? a = #C1, required core::int b = #C1}) → void {}
+}
+class C extends self::A implements self::B {
+  synthetic constructor •() → self::C
+    : super self::A::•()
+    ;
+  forwarding-stub method method1({required covariant core::int a = #C1}) → void
+    return super.{self::A::method1}(a: a);
+  forwarding-stub method method2({covariant core::int? a = #C1, required core::int b = #C1}) → void
+    return super.{self::A::method2}(a: a, b: b);
+}
+class D extends self::C {
+  synthetic constructor •() → self::D
+    : super self::C::•()
+    ;
+  method method1({required covariant core::int a = #C1}) → void {}
+  method method2({covariant core::int? a = #C1, required core::int b = #C1}) → void {}
+}
+static method main() → dynamic {}
+
+constants  {
+  #C1 = null
+}
diff --git a/pkg/front_end/testcases/nnbd/combined_required.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd/combined_required.dart.weak.transformed.expect
new file mode 100644
index 0000000..34958ef
--- /dev/null
+++ b/pkg/front_end/testcases/nnbd/combined_required.dart.weak.transformed.expect
@@ -0,0 +1,39 @@
+library /*isNonNullableByDefault*/;
+import self as self;
+import "dart:core" as core;
+
+class A extends core::Object {
+  synthetic constructor •() → self::A
+    : super core::Object::•()
+    ;
+  method method1({required core::int a = #C1}) → void {}
+  method method2({core::int? a = #C1, required core::int b = #C1}) → void {}
+}
+class B extends core::Object {
+  synthetic constructor •() → self::B
+    : super core::Object::•()
+    ;
+  method method1({required covariant core::int a = #C1}) → void {}
+  method method2({covariant core::int? a = #C1, required core::int b = #C1}) → void {}
+}
+class C extends self::A implements self::B {
+  synthetic constructor •() → self::C
+    : super self::A::•()
+    ;
+  forwarding-stub method method1({required covariant core::int a = #C1}) → void
+    return super.{self::A::method1}(a: a);
+  forwarding-stub method method2({covariant core::int? a = #C1, required core::int b = #C1}) → void
+    return super.{self::A::method2}(a: a, b: b);
+}
+class D extends self::C {
+  synthetic constructor •() → self::D
+    : super self::C::•()
+    ;
+  method method1({required covariant core::int a = #C1}) → void {}
+  method method2({covariant core::int? a = #C1, required core::int b = #C1}) → void {}
+}
+static method main() → dynamic {}
+
+constants  {
+  #C1 = null
+}
diff --git a/pkg/front_end/testcases/nnbd/forin.dart.strong.expect b/pkg/front_end/testcases/nnbd/forin.dart.strong.expect
index d772415..0d3c0c9 100644
--- a/pkg/front_end/testcases/nnbd/forin.dart.strong.expect
+++ b/pkg/front_end/testcases/nnbd/forin.dart.strong.expect
@@ -63,7 +63,7 @@
  - 'Iterable' is from 'dart:core'.
   [for (int x in i2) x];
                  ^" in i2 as{TypeError,ForNonNullableByDefault} core::Iterable<dynamic>)
-      #t2.{core::List::add}(x);
+      #t2.{core::List::add}{Invariant}(x);
   } =>#t2;
   for (core::int x in let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/nnbd/forin.dart:12:17: Error: The type 'List<int>?' used in the 'for' loop must implement 'Iterable<dynamic>' because 'List<int>?' is nullable and 'Iterable<dynamic>' isn't.
  - 'List' is from 'dart:core'.
@@ -78,7 +78,7 @@
  - 'Iterable' is from 'dart:core'.
   [for (int x in l2) x];
                  ^" in l2 as{TypeError,ForNonNullableByDefault} core::Iterable<dynamic>)
-      #t5.{core::List::add}(x);
+      #t5.{core::List::add}{Invariant}(x);
   } =>#t5;
   for (final dynamic #t7 in let final<BottomType> #t8 = invalid-expression "pkg/front_end/testcases/nnbd/forin.dart:15:17: Error: The type 'Object' used in the 'for' loop must implement 'Iterable<dynamic>'.
  - 'Object' is from 'dart:core'.
@@ -96,7 +96,7 @@
   [for (int x in o1) x];
                  ^" in o1 as{TypeError,ForNonNullableByDefault} core::Iterable<dynamic>) {
       core::int x = #t10 as{TypeError,ForDynamic,ForNonNullableByDefault} core::int;
-      #t9.{core::List::add}(x);
+      #t9.{core::List::add}{Invariant}(x);
     }
   } =>#t9;
   for (final dynamic #t12 in let final<BottomType> #t13 = invalid-expression "pkg/front_end/testcases/nnbd/forin.dart:18:17: Error: The type 'Object?' used in the 'for' loop must implement 'Iterable<dynamic>'.
@@ -115,7 +115,7 @@
   [for (int x in o2) x];
                  ^" in o2 as{TypeError,ForNonNullableByDefault} core::Iterable<dynamic>) {
       core::int x = #t15 as{TypeError,ForDynamic,ForNonNullableByDefault} core::int;
-      #t14.{core::List::add}(x);
+      #t14.{core::List::add}{Invariant}(x);
     }
   } =>#t14;
 }
@@ -125,14 +125,14 @@
   block {
     final core::List<core::int> #t17 = <core::int>[];
     for (core::int x in i1)
-      #t17.{core::List::add}(x);
+      #t17.{core::List::add}{Invariant}(x);
   } =>#t17;
   for (core::int x in l1)
     x;
   block {
     final core::List<core::int> #t18 = <core::int>[];
     for (core::int x in l1)
-      #t18.{core::List::add}(x);
+      #t18.{core::List::add}{Invariant}(x);
   } =>#t18;
   for (final dynamic #t19 in d as{TypeError,ForDynamic,ForNonNullableByDefault} core::Iterable<dynamic>) {
     core::int x = #t19 as{TypeError,ForDynamic,ForNonNullableByDefault} core::int;
@@ -142,7 +142,7 @@
     final core::List<core::int> #t20 = <core::int>[];
     for (final dynamic #t21 in d as{TypeError,ForDynamic,ForNonNullableByDefault} core::Iterable<dynamic>) {
       core::int x = #t21 as{TypeError,ForDynamic,ForNonNullableByDefault} core::int;
-      #t20.{core::List::add}(x);
+      #t20.{core::List::add}{Invariant}(x);
     }
   } =>#t20;
 }
diff --git a/pkg/front_end/testcases/nnbd/forin.dart.strong.transformed.expect b/pkg/front_end/testcases/nnbd/forin.dart.strong.transformed.expect
index 46e52d4..a4e5658 100644
--- a/pkg/front_end/testcases/nnbd/forin.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/nnbd/forin.dart.strong.transformed.expect
@@ -71,7 +71,7 @@
                  ^" in let core::Iterable<core::int>? #t5 = i2 in #t5.==(null) ?{core::Iterable<dynamic>} #t5 as{TypeError,ForNonNullableByDefault} core::Iterable<dynamic> : #t5{core::Iterable<dynamic>}).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         core::int x = :sync-for-iterator.{core::Iterator::current};
-        #t3.{core::List::add}(x);
+        #t3.{core::List::add}{Invariant}(x);
       }
     }
   } =>#t3;
@@ -96,7 +96,7 @@
                  ^" in let core::List<core::int>? #t10 = l2 in #t10.==(null) ?{core::Iterable<dynamic>} #t10 as{TypeError,ForNonNullableByDefault} core::Iterable<dynamic> : #t10{core::Iterable<dynamic>}).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         core::int x = :sync-for-iterator.{core::Iterator::current};
-        #t8.{core::List::add}(x);
+        #t8.{core::List::add}{Invariant}(x);
       }
     }
   } =>#t8;
@@ -126,7 +126,7 @@
         final dynamic #t15 = :sync-for-iterator.{core::Iterator::current};
         {
           core::int x = #t15 as{TypeError,ForDynamic,ForNonNullableByDefault} core::int;
-          #t13.{core::List::add}(x);
+          #t13.{core::List::add}{Invariant}(x);
         }
       }
     }
@@ -157,7 +157,7 @@
         final dynamic #t20 = :sync-for-iterator.{core::Iterator::current};
         {
           core::int x = #t20 as{TypeError,ForDynamic,ForNonNullableByDefault} core::int;
-          #t18.{core::List::add}(x);
+          #t18.{core::List::add}{Invariant}(x);
         }
       }
     }
@@ -177,7 +177,7 @@
       core::Iterator<core::int> :sync-for-iterator = i1.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         core::int x = :sync-for-iterator.{core::Iterator::current};
-        #t21.{core::List::add}(x);
+        #t21.{core::List::add}{Invariant}(x);
       }
     }
   } =>#t21;
@@ -194,7 +194,7 @@
       core::Iterator<core::int> :sync-for-iterator = l1.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         core::int x = :sync-for-iterator.{core::Iterator::current};
-        #t22.{core::List::add}(x);
+        #t22.{core::List::add}{Invariant}(x);
       }
     }
   } =>#t22;
@@ -216,7 +216,7 @@
         final dynamic #t25 = :sync-for-iterator.{core::Iterator::current};
         {
           core::int x = #t25 as{TypeError,ForDynamic,ForNonNullableByDefault} core::int;
-          #t24.{core::List::add}(x);
+          #t24.{core::List::add}{Invariant}(x);
         }
       }
     }
diff --git a/pkg/front_end/testcases/nnbd/forin.dart.weak.expect b/pkg/front_end/testcases/nnbd/forin.dart.weak.expect
index d772415..0d3c0c9 100644
--- a/pkg/front_end/testcases/nnbd/forin.dart.weak.expect
+++ b/pkg/front_end/testcases/nnbd/forin.dart.weak.expect
@@ -63,7 +63,7 @@
  - 'Iterable' is from 'dart:core'.
   [for (int x in i2) x];
                  ^" in i2 as{TypeError,ForNonNullableByDefault} core::Iterable<dynamic>)
-      #t2.{core::List::add}(x);
+      #t2.{core::List::add}{Invariant}(x);
   } =>#t2;
   for (core::int x in let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/nnbd/forin.dart:12:17: Error: The type 'List<int>?' used in the 'for' loop must implement 'Iterable<dynamic>' because 'List<int>?' is nullable and 'Iterable<dynamic>' isn't.
  - 'List' is from 'dart:core'.
@@ -78,7 +78,7 @@
  - 'Iterable' is from 'dart:core'.
   [for (int x in l2) x];
                  ^" in l2 as{TypeError,ForNonNullableByDefault} core::Iterable<dynamic>)
-      #t5.{core::List::add}(x);
+      #t5.{core::List::add}{Invariant}(x);
   } =>#t5;
   for (final dynamic #t7 in let final<BottomType> #t8 = invalid-expression "pkg/front_end/testcases/nnbd/forin.dart:15:17: Error: The type 'Object' used in the 'for' loop must implement 'Iterable<dynamic>'.
  - 'Object' is from 'dart:core'.
@@ -96,7 +96,7 @@
   [for (int x in o1) x];
                  ^" in o1 as{TypeError,ForNonNullableByDefault} core::Iterable<dynamic>) {
       core::int x = #t10 as{TypeError,ForDynamic,ForNonNullableByDefault} core::int;
-      #t9.{core::List::add}(x);
+      #t9.{core::List::add}{Invariant}(x);
     }
   } =>#t9;
   for (final dynamic #t12 in let final<BottomType> #t13 = invalid-expression "pkg/front_end/testcases/nnbd/forin.dart:18:17: Error: The type 'Object?' used in the 'for' loop must implement 'Iterable<dynamic>'.
@@ -115,7 +115,7 @@
   [for (int x in o2) x];
                  ^" in o2 as{TypeError,ForNonNullableByDefault} core::Iterable<dynamic>) {
       core::int x = #t15 as{TypeError,ForDynamic,ForNonNullableByDefault} core::int;
-      #t14.{core::List::add}(x);
+      #t14.{core::List::add}{Invariant}(x);
     }
   } =>#t14;
 }
@@ -125,14 +125,14 @@
   block {
     final core::List<core::int> #t17 = <core::int>[];
     for (core::int x in i1)
-      #t17.{core::List::add}(x);
+      #t17.{core::List::add}{Invariant}(x);
   } =>#t17;
   for (core::int x in l1)
     x;
   block {
     final core::List<core::int> #t18 = <core::int>[];
     for (core::int x in l1)
-      #t18.{core::List::add}(x);
+      #t18.{core::List::add}{Invariant}(x);
   } =>#t18;
   for (final dynamic #t19 in d as{TypeError,ForDynamic,ForNonNullableByDefault} core::Iterable<dynamic>) {
     core::int x = #t19 as{TypeError,ForDynamic,ForNonNullableByDefault} core::int;
@@ -142,7 +142,7 @@
     final core::List<core::int> #t20 = <core::int>[];
     for (final dynamic #t21 in d as{TypeError,ForDynamic,ForNonNullableByDefault} core::Iterable<dynamic>) {
       core::int x = #t21 as{TypeError,ForDynamic,ForNonNullableByDefault} core::int;
-      #t20.{core::List::add}(x);
+      #t20.{core::List::add}{Invariant}(x);
     }
   } =>#t20;
 }
diff --git a/pkg/front_end/testcases/nnbd/forin.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd/forin.dart.weak.transformed.expect
index b8054bf..43b2e84 100644
--- a/pkg/front_end/testcases/nnbd/forin.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/nnbd/forin.dart.weak.transformed.expect
@@ -71,7 +71,7 @@
                  ^" in i2).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         core::int x = :sync-for-iterator.{core::Iterator::current};
-        #t2.{core::List::add}(x);
+        #t2.{core::List::add}{Invariant}(x);
       }
     }
   } =>#t2;
@@ -96,7 +96,7 @@
                  ^" in l2).{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         core::int x = :sync-for-iterator.{core::Iterator::current};
-        #t5.{core::List::add}(x);
+        #t5.{core::List::add}{Invariant}(x);
       }
     }
   } =>#t5;
@@ -126,7 +126,7 @@
         final dynamic #t11 = :sync-for-iterator.{core::Iterator::current};
         {
           core::int x = #t11 as{TypeError,ForDynamic,ForNonNullableByDefault} core::int;
-          #t9.{core::List::add}(x);
+          #t9.{core::List::add}{Invariant}(x);
         }
       }
     }
@@ -157,7 +157,7 @@
         final dynamic #t16 = :sync-for-iterator.{core::Iterator::current};
         {
           core::int x = #t16 as{TypeError,ForDynamic,ForNonNullableByDefault} core::int;
-          #t14.{core::List::add}(x);
+          #t14.{core::List::add}{Invariant}(x);
         }
       }
     }
@@ -177,7 +177,7 @@
       core::Iterator<core::int> :sync-for-iterator = i1.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         core::int x = :sync-for-iterator.{core::Iterator::current};
-        #t17.{core::List::add}(x);
+        #t17.{core::List::add}{Invariant}(x);
       }
     }
   } =>#t17;
@@ -194,7 +194,7 @@
       core::Iterator<core::int> :sync-for-iterator = l1.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         core::int x = :sync-for-iterator.{core::Iterator::current};
-        #t18.{core::List::add}(x);
+        #t18.{core::List::add}{Invariant}(x);
       }
     }
   } =>#t18;
@@ -216,7 +216,7 @@
         final dynamic #t21 = :sync-for-iterator.{core::Iterator::current};
         {
           core::int x = #t21 as{TypeError,ForDynamic,ForNonNullableByDefault} core::int;
-          #t20.{core::List::add}(x);
+          #t20.{core::List::add}{Invariant}(x);
         }
       }
     }
diff --git a/pkg/front_end/testcases/nnbd/issue41700b.dart.strong.expect b/pkg/front_end/testcases/nnbd/issue41700b.dart.strong.expect
index 0ba35af..f3fd260 100644
--- a/pkg/front_end/testcases/nnbd/issue41700b.dart.strong.expect
+++ b/pkg/front_end/testcases/nnbd/issue41700b.dart.strong.expect
@@ -2,7 +2,7 @@
 //
 // Problems in library:
 //
-// pkg/front_end/testcases/nnbd/issue41700b.dart:8:12: Error: A value of type 'Null' can't be assigned to a variable of type 'Null' because 'Null' is nullable and 'Null' isn't.
+// pkg/front_end/testcases/nnbd/issue41700b.dart:8:12: Error: The value 'null' can't be assigned to a variable of type 'Null' because 'Null' is not nullable.
 //  - 'Null' is from 'pkg/front_end/testcases/nnbd/issue41700b.dart'.
 //   Null x = null;
 //            ^
@@ -28,7 +28,7 @@
     ;
 }
 static method test() → dynamic {
-  self::Null x = let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd/issue41700b.dart:8:12: Error: A value of type 'Null' can't be assigned to a variable of type 'Null' because 'Null' is nullable and 'Null' isn't.
+  self::Null x = let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd/issue41700b.dart:8:12: Error: The value 'null' can't be assigned to a variable of type 'Null' because 'Null' is not nullable.
  - 'Null' is from 'pkg/front_end/testcases/nnbd/issue41700b.dart'.
   Null x = null;
            ^" in null as{TypeError,ForNonNullableByDefault} self::Null;
diff --git a/pkg/front_end/testcases/nnbd/issue41700b.dart.strong.transformed.expect b/pkg/front_end/testcases/nnbd/issue41700b.dart.strong.transformed.expect
index 43bc84a..14adf33 100644
--- a/pkg/front_end/testcases/nnbd/issue41700b.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/nnbd/issue41700b.dart.strong.transformed.expect
@@ -2,7 +2,7 @@
 //
 // Problems in library:
 //
-// pkg/front_end/testcases/nnbd/issue41700b.dart:8:12: Error: A value of type 'Null' can't be assigned to a variable of type 'Null' because 'Null' is nullable and 'Null' isn't.
+// pkg/front_end/testcases/nnbd/issue41700b.dart:8:12: Error: The value 'null' can't be assigned to a variable of type 'Null' because 'Null' is not nullable.
 //  - 'Null' is from 'pkg/front_end/testcases/nnbd/issue41700b.dart'.
 //   Null x = null;
 //            ^
@@ -28,7 +28,7 @@
     ;
 }
 static method test() → dynamic {
-  self::Null x = let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd/issue41700b.dart:8:12: Error: A value of type 'Null' can't be assigned to a variable of type 'Null' because 'Null' is nullable and 'Null' isn't.
+  self::Null x = let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd/issue41700b.dart:8:12: Error: The value 'null' can't be assigned to a variable of type 'Null' because 'Null' is not nullable.
  - 'Null' is from 'pkg/front_end/testcases/nnbd/issue41700b.dart'.
   Null x = null;
            ^" in let Null #t2 = null in #t2.==(null) ?{self::Null} #t2 as{TypeError,ForNonNullableByDefault} self::Null : #t2{self::Null};
diff --git a/pkg/front_end/testcases/nnbd/issue41700b.dart.weak.expect b/pkg/front_end/testcases/nnbd/issue41700b.dart.weak.expect
index 0ba35af..f3fd260 100644
--- a/pkg/front_end/testcases/nnbd/issue41700b.dart.weak.expect
+++ b/pkg/front_end/testcases/nnbd/issue41700b.dart.weak.expect
@@ -2,7 +2,7 @@
 //
 // Problems in library:
 //
-// pkg/front_end/testcases/nnbd/issue41700b.dart:8:12: Error: A value of type 'Null' can't be assigned to a variable of type 'Null' because 'Null' is nullable and 'Null' isn't.
+// pkg/front_end/testcases/nnbd/issue41700b.dart:8:12: Error: The value 'null' can't be assigned to a variable of type 'Null' because 'Null' is not nullable.
 //  - 'Null' is from 'pkg/front_end/testcases/nnbd/issue41700b.dart'.
 //   Null x = null;
 //            ^
@@ -28,7 +28,7 @@
     ;
 }
 static method test() → dynamic {
-  self::Null x = let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd/issue41700b.dart:8:12: Error: A value of type 'Null' can't be assigned to a variable of type 'Null' because 'Null' is nullable and 'Null' isn't.
+  self::Null x = let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd/issue41700b.dart:8:12: Error: The value 'null' can't be assigned to a variable of type 'Null' because 'Null' is not nullable.
  - 'Null' is from 'pkg/front_end/testcases/nnbd/issue41700b.dart'.
   Null x = null;
            ^" in null as{TypeError,ForNonNullableByDefault} self::Null;
diff --git a/pkg/front_end/testcases/nnbd/issue41700b.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd/issue41700b.dart.weak.transformed.expect
index a18115f..18bf619 100644
--- a/pkg/front_end/testcases/nnbd/issue41700b.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/nnbd/issue41700b.dart.weak.transformed.expect
@@ -2,7 +2,7 @@
 //
 // Problems in library:
 //
-// pkg/front_end/testcases/nnbd/issue41700b.dart:8:12: Error: A value of type 'Null' can't be assigned to a variable of type 'Null' because 'Null' is nullable and 'Null' isn't.
+// pkg/front_end/testcases/nnbd/issue41700b.dart:8:12: Error: The value 'null' can't be assigned to a variable of type 'Null' because 'Null' is not nullable.
 //  - 'Null' is from 'pkg/front_end/testcases/nnbd/issue41700b.dart'.
 //   Null x = null;
 //            ^
@@ -28,7 +28,7 @@
     ;
 }
 static method test() → dynamic {
-  self::Null x = let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd/issue41700b.dart:8:12: Error: A value of type 'Null' can't be assigned to a variable of type 'Null' because 'Null' is nullable and 'Null' isn't.
+  self::Null x = let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd/issue41700b.dart:8:12: Error: The value 'null' can't be assigned to a variable of type 'Null' because 'Null' is not nullable.
  - 'Null' is from 'pkg/front_end/testcases/nnbd/issue41700b.dart'.
   Null x = null;
            ^" in null;
diff --git a/pkg/front_end/testcases/nnbd/issue42758.dart.strong.expect b/pkg/front_end/testcases/nnbd/issue42758.dart.strong.expect
index ec865de..e18d2d3 100644
--- a/pkg/front_end/testcases/nnbd/issue42758.dart.strong.expect
+++ b/pkg/front_end/testcases/nnbd/issue42758.dart.strong.expect
@@ -82,14 +82,14 @@
   core::List<Never> l1 = block {
     final core::List<Never> #t1 = <Never>[];
     for (final Never #t2 in n1)
-      #t1.{core::List::add}(#t2);
+      #t1.{core::List::add}{Invariant}(#t2);
   } =>#t1;
   core::List<Never> l2 = block {
     final core::List<Never> #t3 = <Never>[];
     final core::Iterable<Never>? #t4 = n1;
     if(!#t4.{core::Object::==}(null))
       for (final Never #t5 in #t4{core::Iterable<Never>})
-        #t3.{core::List::add}(#t5);
+        #t3.{core::List::add}{Invariant}(#t5);
   } =>#t3;
   core::List<dynamic> l3 = <dynamic>[invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:8:16: Error: Can't spread a value with static type 'Never?'.
   var l3 = [...n2];
@@ -99,7 +99,7 @@
     final core::Iterable<Never>? #t7 = n2;
     if(!#t7.{core::Object::==}(null))
       for (final Never #t8 in #t7{core::Iterable<Never>})
-        #t6.{core::List::add}(#t8);
+        #t6.{core::List::add}{Invariant}(#t8);
   } =>#t6;
   core::List<dynamic> l5 = <dynamic>[invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:10:16: Error: Can't spread a value with static type 'Null'.
   var l5 = [...n3];
@@ -109,65 +109,65 @@
     final core::Iterable<Never>? #t10 = n3;
     if(!#t10.{core::Object::==}(null))
       for (final Never #t11 in #t10{core::Iterable<Never>})
-        #t9.{core::List::add}(#t11);
+        #t9.{core::List::add}{Invariant}(#t11);
   } =>#t9;
   core::Set<Never> s1 = block {
     final core::Set<Never> #t12 = col::LinkedHashSet::•<Never>();
     for (final Never #t13 in n1)
-      #t12.{core::Set::add}(#t13);
-    #t12.{core::Set::add}(n1);
+      #t12.{core::Set::add}{Invariant}(#t13);
+    #t12.{core::Set::add}{Invariant}(n1);
   } =>#t12;
   core::Set<Never> s2 = block {
     final core::Set<Never> #t14 = col::LinkedHashSet::•<Never>();
     final core::Iterable<Never>? #t15 = n1;
     if(!#t15.{core::Object::==}(null))
       for (final Never #t16 in #t15{core::Iterable<Never>})
-        #t14.{core::Set::add}(#t16);
-    #t14.{core::Set::add}(n1);
+        #t14.{core::Set::add}{Invariant}(#t16);
+    #t14.{core::Set::add}{Invariant}(n1);
   } =>#t14;
   core::Set<dynamic> s3 = block {
     final core::Set<dynamic> #t17 = col::LinkedHashSet::•<dynamic>();
-    #t17.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:14:16: Error: Can't spread a value with static type 'Never?'.
+    #t17.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:14:16: Error: Can't spread a value with static type 'Never?'.
   var s3 = {...n2, n1};
                ^");
-    #t17.{core::Set::add}(n1);
+    #t17.{core::Set::add}{Invariant}(n1);
   } =>#t17;
   core::Set<Never> s4 = block {
     final core::Set<Never> #t18 = col::LinkedHashSet::•<Never>();
     final core::Iterable<Never>? #t19 = n2;
     if(!#t19.{core::Object::==}(null))
       for (final Never #t20 in #t19{core::Iterable<Never>})
-        #t18.{core::Set::add}(#t20);
-    #t18.{core::Set::add}(n1);
+        #t18.{core::Set::add}{Invariant}(#t20);
+    #t18.{core::Set::add}{Invariant}(n1);
   } =>#t18;
   core::Set<dynamic> s5 = block {
     final core::Set<dynamic> #t21 = col::LinkedHashSet::•<dynamic>();
-    #t21.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:16:16: Error: Can't spread a value with static type 'Null'.
+    #t21.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:16:16: Error: Can't spread a value with static type 'Null'.
   var s5 = {...n3, n1};
                ^");
-    #t21.{core::Set::add}(n1);
+    #t21.{core::Set::add}{Invariant}(n1);
   } =>#t21;
   core::Set<Never> s6 = block {
     final core::Set<Never> #t22 = col::LinkedHashSet::•<Never>();
     final core::Iterable<Never>? #t23 = n3;
     if(!#t23.{core::Object::==}(null))
       for (final Never #t24 in #t23{core::Iterable<Never>})
-        #t22.{core::Set::add}(#t24);
-    #t22.{core::Set::add}(n1);
+        #t22.{core::Set::add}{Invariant}(#t24);
+    #t22.{core::Set::add}{Invariant}(n1);
   } =>#t22;
   core::Map<Never, Never> m1 = block {
     final core::Map<Never, Never> #t25 = <Never, Never>{};
     for (final core::MapEntry<Never, Never> #t26 in n1.{core::Map::entries})
-      #t25.{core::Map::[]=}(#t26.{core::MapEntry::key}, #t26.{core::MapEntry::value});
-    #t25.{core::Map::[]=}(n1, n1);
+      #t25.{core::Map::[]=}{Invariant}(#t26.{core::MapEntry::key}, #t26.{core::MapEntry::value});
+    #t25.{core::Map::[]=}{Invariant}(n1, n1);
   } =>#t25;
   core::Map<Never, Never> m2 = block {
     final core::Map<Never, Never> #t27 = <Never, Never>{};
     final core::Map<Never, Never>? #t28 = n1;
     if(!#t28.{core::Object::==}(null))
       for (final core::MapEntry<Never, Never> #t29 in #t28{core::Map<Never, Never>}.{core::Map::entries})
-        #t27.{core::Map::[]=}(#t29.{core::MapEntry::key}, #t29.{core::MapEntry::value});
-    #t27.{core::Map::[]=}(n1, n1);
+        #t27.{core::Map::[]=}{Invariant}(#t29.{core::MapEntry::key}, #t29.{core::MapEntry::value});
+    #t27.{core::Map::[]=}{Invariant}(n1, n1);
   } =>#t27;
   core::Map<dynamic, dynamic> m3 = <dynamic, dynamic>{invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:20:16: Error: Can't spread a value with static type 'Never?'.
   var m3 = {...n2, n1: n1};
@@ -177,8 +177,8 @@
     final core::Map<Never, Never>? #t31 = n2;
     if(!#t31.{core::Object::==}(null))
       for (final core::MapEntry<Never, Never> #t32 in #t31{core::Map<Never, Never>}.{core::Map::entries})
-        #t30.{core::Map::[]=}(#t32.{core::MapEntry::key}, #t32.{core::MapEntry::value});
-    #t30.{core::Map::[]=}(n1, n1);
+        #t30.{core::Map::[]=}{Invariant}(#t32.{core::MapEntry::key}, #t32.{core::MapEntry::value});
+    #t30.{core::Map::[]=}{Invariant}(n1, n1);
   } =>#t30;
   core::Map<dynamic, dynamic> m5 = <dynamic, dynamic>{invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:22:16: Error: Can't spread a value with static type 'Null'.
   var m5 = {...n3, n1: n1};
@@ -188,22 +188,22 @@
     final core::Map<Never, Never>? #t34 = n3;
     if(!#t34.{core::Object::==}(null))
       for (final core::MapEntry<Never, Never> #t35 in #t34{core::Map<Never, Never>}.{core::Map::entries})
-        #t33.{core::Map::[]=}(#t35.{core::MapEntry::key}, #t35.{core::MapEntry::value});
-    #t33.{core::Map::[]=}(n1, n1);
+        #t33.{core::Map::[]=}{Invariant}(#t35.{core::MapEntry::key}, #t35.{core::MapEntry::value});
+    #t33.{core::Map::[]=}{Invariant}(n1, n1);
   } =>#t33;
 }
 static method test2<N1 extends Never = Never, N2 extends Never? = Never?, N3 extends Null = Null>(self::test2::N1 n1, self::test2::N2% n2, self::test2::N3% n3) → dynamic {
   core::List<Never> l1 = block {
     final core::List<Never> #t36 = <Never>[];
     for (final Never #t37 in n1)
-      #t36.{core::List::add}(#t37);
+      #t36.{core::List::add}{Invariant}(#t37);
   } =>#t36;
   core::List<Never> l2 = block {
     final core::List<Never> #t38 = <Never>[];
     final core::Iterable<Never>? #t39 = n1;
     if(!#t39.{core::Object::==}(null))
       for (final Never #t40 in #t39{core::Iterable<Never>})
-        #t38.{core::List::add}(#t40);
+        #t38.{core::List::add}{Invariant}(#t40);
   } =>#t38;
   core::List<dynamic> l3 = <dynamic>[invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:30:16: Error: Can't spread a value with static type 'N2'.
   var l3 = [...n2];
@@ -213,7 +213,7 @@
     final core::Iterable<Never>? #t42 = n2;
     if(!#t42.{core::Object::==}(null))
       for (final Never #t43 in #t42{core::Iterable<Never>})
-        #t41.{core::List::add}(#t43);
+        #t41.{core::List::add}{Invariant}(#t43);
   } =>#t41;
   core::List<dynamic> l5 = <dynamic>[invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:32:16: Error: Can't spread a value with static type 'N3'.
   var l5 = [...n3];
@@ -223,65 +223,65 @@
     final core::Iterable<Never>? #t45 = n3;
     if(!#t45.{core::Object::==}(null))
       for (final Never #t46 in #t45{core::Iterable<Never>})
-        #t44.{core::List::add}(#t46);
+        #t44.{core::List::add}{Invariant}(#t46);
   } =>#t44;
   core::Set<self::test2::N1> s1 = block {
     final core::Set<self::test2::N1> #t47 = col::LinkedHashSet::•<self::test2::N1>();
     for (final self::test2::N1 #t48 in n1)
-      #t47.{core::Set::add}(#t48);
-    #t47.{core::Set::add}(n1);
+      #t47.{core::Set::add}{Invariant}(#t48);
+    #t47.{core::Set::add}{Invariant}(n1);
   } =>#t47;
   core::Set<self::test2::N1> s2 = block {
     final core::Set<self::test2::N1> #t49 = col::LinkedHashSet::•<self::test2::N1>();
     final core::Iterable<self::test2::N1>? #t50 = n1;
     if(!#t50.{core::Object::==}(null))
       for (final self::test2::N1 #t51 in #t50{core::Iterable<self::test2::N1>})
-        #t49.{core::Set::add}(#t51);
-    #t49.{core::Set::add}(n1);
+        #t49.{core::Set::add}{Invariant}(#t51);
+    #t49.{core::Set::add}{Invariant}(n1);
   } =>#t49;
   core::Set<dynamic> s3 = block {
     final core::Set<dynamic> #t52 = col::LinkedHashSet::•<dynamic>();
-    #t52.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:36:16: Error: Can't spread a value with static type 'N2'.
+    #t52.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:36:16: Error: Can't spread a value with static type 'N2'.
   var s3 = {...n2, n1};
                ^");
-    #t52.{core::Set::add}(n1);
+    #t52.{core::Set::add}{Invariant}(n1);
   } =>#t52;
   core::Set<self::test2::N1> s4 = block {
     final core::Set<self::test2::N1> #t53 = col::LinkedHashSet::•<self::test2::N1>();
     final core::Iterable<self::test2::N1>? #t54 = n2;
     if(!#t54.{core::Object::==}(null))
       for (final self::test2::N1 #t55 in #t54{core::Iterable<self::test2::N1>})
-        #t53.{core::Set::add}(#t55);
-    #t53.{core::Set::add}(n1);
+        #t53.{core::Set::add}{Invariant}(#t55);
+    #t53.{core::Set::add}{Invariant}(n1);
   } =>#t53;
   core::Set<dynamic> s5 = block {
     final core::Set<dynamic> #t56 = col::LinkedHashSet::•<dynamic>();
-    #t56.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:38:16: Error: Can't spread a value with static type 'N3'.
+    #t56.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:38:16: Error: Can't spread a value with static type 'N3'.
   var s5 = {...n3, n1};
                ^");
-    #t56.{core::Set::add}(n1);
+    #t56.{core::Set::add}{Invariant}(n1);
   } =>#t56;
   core::Set<self::test2::N1> s6 = block {
     final core::Set<self::test2::N1> #t57 = col::LinkedHashSet::•<self::test2::N1>();
     final core::Iterable<self::test2::N1>? #t58 = n3;
     if(!#t58.{core::Object::==}(null))
       for (final self::test2::N1 #t59 in #t58{core::Iterable<self::test2::N1>})
-        #t57.{core::Set::add}(#t59);
-    #t57.{core::Set::add}(n1);
+        #t57.{core::Set::add}{Invariant}(#t59);
+    #t57.{core::Set::add}{Invariant}(n1);
   } =>#t57;
   core::Map<self::test2::N1, self::test2::N1> m1 = block {
     final core::Map<self::test2::N1, self::test2::N1> #t60 = <self::test2::N1, self::test2::N1>{};
     for (final core::MapEntry<self::test2::N1, self::test2::N1> #t61 in n1.{core::Map::entries})
-      #t60.{core::Map::[]=}(#t61.{core::MapEntry::key}, #t61.{core::MapEntry::value});
-    #t60.{core::Map::[]=}(n1, n1);
+      #t60.{core::Map::[]=}{Invariant}(#t61.{core::MapEntry::key}, #t61.{core::MapEntry::value});
+    #t60.{core::Map::[]=}{Invariant}(n1, n1);
   } =>#t60;
   core::Map<self::test2::N1, self::test2::N1> m2 = block {
     final core::Map<self::test2::N1, self::test2::N1> #t62 = <self::test2::N1, self::test2::N1>{};
     final core::Map<self::test2::N1, self::test2::N1>? #t63 = n1;
     if(!#t63.{core::Object::==}(null))
       for (final core::MapEntry<self::test2::N1, self::test2::N1> #t64 in #t63{core::Map<self::test2::N1, self::test2::N1>}.{core::Map::entries})
-        #t62.{core::Map::[]=}(#t64.{core::MapEntry::key}, #t64.{core::MapEntry::value});
-    #t62.{core::Map::[]=}(n1, n1);
+        #t62.{core::Map::[]=}{Invariant}(#t64.{core::MapEntry::key}, #t64.{core::MapEntry::value});
+    #t62.{core::Map::[]=}{Invariant}(n1, n1);
   } =>#t62;
   core::Map<dynamic, dynamic> m3 = <dynamic, dynamic>{invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:42:16: Error: Can't spread a value with static type 'N2'.
   var m3 = {...n2, n1: n1};
@@ -291,8 +291,8 @@
     final core::Map<self::test2::N1, self::test2::N1>? #t66 = n2;
     if(!#t66.{core::Object::==}(null))
       for (final core::MapEntry<self::test2::N1, self::test2::N1> #t67 in #t66{core::Map<self::test2::N1, self::test2::N1>}.{core::Map::entries})
-        #t65.{core::Map::[]=}(#t67.{core::MapEntry::key}, #t67.{core::MapEntry::value});
-    #t65.{core::Map::[]=}(n1, n1);
+        #t65.{core::Map::[]=}{Invariant}(#t67.{core::MapEntry::key}, #t67.{core::MapEntry::value});
+    #t65.{core::Map::[]=}{Invariant}(n1, n1);
   } =>#t65;
   core::Map<dynamic, dynamic> m5 = <dynamic, dynamic>{invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:44:16: Error: Can't spread a value with static type 'N3'.
   var m5 = {...n3, n1: n1};
@@ -302,8 +302,8 @@
     final core::Map<self::test2::N1, self::test2::N1>? #t69 = n3;
     if(!#t69.{core::Object::==}(null))
       for (final core::MapEntry<self::test2::N1, self::test2::N1> #t70 in #t69{core::Map<self::test2::N1, self::test2::N1>}.{core::Map::entries})
-        #t68.{core::Map::[]=}(#t70.{core::MapEntry::key}, #t70.{core::MapEntry::value});
-    #t68.{core::Map::[]=}(n1, n1);
+        #t68.{core::Map::[]=}{Invariant}(#t70.{core::MapEntry::key}, #t70.{core::MapEntry::value});
+    #t68.{core::Map::[]=}{Invariant}(n1, n1);
   } =>#t68;
 }
 static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/issue42758.dart.strong.transformed.expect b/pkg/front_end/testcases/nnbd/issue42758.dart.strong.transformed.expect
index 30a2fce..b4eff37 100644
--- a/pkg/front_end/testcases/nnbd/issue42758.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/nnbd/issue42758.dart.strong.transformed.expect
@@ -82,7 +82,7 @@
   core::List<Never> l1 = block {
     final core::List<Never> #t1 = <Never>[];
     for (final Never #t2 in n1)
-      #t1.{core::List::add}(#t2);
+      #t1.{core::List::add}{Invariant}(#t2);
   } =>#t1;
   core::List<Never> l2 = block {
     final core::List<Never> #t3 = <Never>[];
@@ -91,7 +91,7 @@
       core::Iterator<Never> :sync-for-iterator = #t4{core::Iterable<Never>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final Never #t5 = :sync-for-iterator.{core::Iterator::current};
-        #t3.{core::List::add}(#t5);
+        #t3.{core::List::add}{Invariant}(#t5);
       }
     }
   } =>#t3;
@@ -105,7 +105,7 @@
       core::Iterator<Never> :sync-for-iterator = #t7{core::Iterable<Never>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final Never #t8 = :sync-for-iterator.{core::Iterator::current};
-        #t6.{core::List::add}(#t8);
+        #t6.{core::List::add}{Invariant}(#t8);
       }
     }
   } =>#t6;
@@ -119,15 +119,15 @@
       core::Iterator<Never> :sync-for-iterator = #t10{core::Iterable<Never>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final Never #t11 = :sync-for-iterator.{core::Iterator::current};
-        #t9.{core::List::add}(#t11);
+        #t9.{core::List::add}{Invariant}(#t11);
       }
     }
   } =>#t9;
   core::Set<Never> s1 = block {
     final core::Set<Never> #t12 = new col::_CompactLinkedHashSet::•<Never>();
     for (final Never #t13 in n1)
-      #t12.{core::Set::add}(#t13);
-    #t12.{core::Set::add}(n1);
+      #t12.{core::Set::add}{Invariant}(#t13);
+    #t12.{core::Set::add}{Invariant}(n1);
   } =>#t12;
   core::Set<Never> s2 = block {
     final core::Set<Never> #t14 = new col::_CompactLinkedHashSet::•<Never>();
@@ -136,17 +136,17 @@
       core::Iterator<Never> :sync-for-iterator = #t15{core::Iterable<Never>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final Never #t16 = :sync-for-iterator.{core::Iterator::current};
-        #t14.{core::Set::add}(#t16);
+        #t14.{core::Set::add}{Invariant}(#t16);
       }
     }
-    #t14.{core::Set::add}(n1);
+    #t14.{core::Set::add}{Invariant}(n1);
   } =>#t14;
   core::Set<dynamic> s3 = block {
     final core::Set<dynamic> #t17 = new col::_CompactLinkedHashSet::•<dynamic>();
-    #t17.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:14:16: Error: Can't spread a value with static type 'Never?'.
+    #t17.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:14:16: Error: Can't spread a value with static type 'Never?'.
   var s3 = {...n2, n1};
                ^");
-    #t17.{core::Set::add}(n1);
+    #t17.{core::Set::add}{Invariant}(n1);
   } =>#t17;
   core::Set<Never> s4 = block {
     final core::Set<Never> #t18 = new col::_CompactLinkedHashSet::•<Never>();
@@ -155,17 +155,17 @@
       core::Iterator<Never> :sync-for-iterator = #t19{core::Iterable<Never>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final Never #t20 = :sync-for-iterator.{core::Iterator::current};
-        #t18.{core::Set::add}(#t20);
+        #t18.{core::Set::add}{Invariant}(#t20);
       }
     }
-    #t18.{core::Set::add}(n1);
+    #t18.{core::Set::add}{Invariant}(n1);
   } =>#t18;
   core::Set<dynamic> s5 = block {
     final core::Set<dynamic> #t21 = new col::_CompactLinkedHashSet::•<dynamic>();
-    #t21.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:16:16: Error: Can't spread a value with static type 'Null'.
+    #t21.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:16:16: Error: Can't spread a value with static type 'Null'.
   var s5 = {...n3, n1};
                ^");
-    #t21.{core::Set::add}(n1);
+    #t21.{core::Set::add}{Invariant}(n1);
   } =>#t21;
   core::Set<Never> s6 = block {
     final core::Set<Never> #t22 = new col::_CompactLinkedHashSet::•<Never>();
@@ -174,10 +174,10 @@
       core::Iterator<Never> :sync-for-iterator = #t23{core::Iterable<Never>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final Never #t24 = :sync-for-iterator.{core::Iterator::current};
-        #t22.{core::Set::add}(#t24);
+        #t22.{core::Set::add}{Invariant}(#t24);
       }
     }
-    #t22.{core::Set::add}(n1);
+    #t22.{core::Set::add}{Invariant}(n1);
   } =>#t22;
   core::Map<Never, Never> m1 = block {
     final core::Map<Never, Never> #t25 = <Never, Never>{};
@@ -185,10 +185,10 @@
       core::Iterator<core::MapEntry<<BottomType>, <BottomType>>> :sync-for-iterator = n1.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<Never, Never> #t26 = :sync-for-iterator.{core::Iterator::current};
-        #t25.{core::Map::[]=}(#t26.{core::MapEntry::key}, #t26.{core::MapEntry::value});
+        #t25.{core::Map::[]=}{Invariant}(#t26.{core::MapEntry::key}, #t26.{core::MapEntry::value});
       }
     }
-    #t25.{core::Map::[]=}(n1, n1);
+    #t25.{core::Map::[]=}{Invariant}(n1, n1);
   } =>#t25;
   core::Map<Never, Never> m2 = block {
     final core::Map<Never, Never> #t27 = <Never, Never>{};
@@ -197,10 +197,10 @@
       core::Iterator<core::MapEntry<Never, Never>> :sync-for-iterator = #t28{core::Map<Never, Never>}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<Never, Never> #t29 = :sync-for-iterator.{core::Iterator::current};
-        #t27.{core::Map::[]=}(#t29.{core::MapEntry::key}, #t29.{core::MapEntry::value});
+        #t27.{core::Map::[]=}{Invariant}(#t29.{core::MapEntry::key}, #t29.{core::MapEntry::value});
       }
     }
-    #t27.{core::Map::[]=}(n1, n1);
+    #t27.{core::Map::[]=}{Invariant}(n1, n1);
   } =>#t27;
   core::Map<dynamic, dynamic> m3 = <dynamic, dynamic>{invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:20:16: Error: Can't spread a value with static type 'Never?'.
   var m3 = {...n2, n1: n1};
@@ -212,10 +212,10 @@
       core::Iterator<core::MapEntry<Never, Never>> :sync-for-iterator = #t31{core::Map<Never, Never>}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<Never, Never> #t32 = :sync-for-iterator.{core::Iterator::current};
-        #t30.{core::Map::[]=}(#t32.{core::MapEntry::key}, #t32.{core::MapEntry::value});
+        #t30.{core::Map::[]=}{Invariant}(#t32.{core::MapEntry::key}, #t32.{core::MapEntry::value});
       }
     }
-    #t30.{core::Map::[]=}(n1, n1);
+    #t30.{core::Map::[]=}{Invariant}(n1, n1);
   } =>#t30;
   core::Map<dynamic, dynamic> m5 = <dynamic, dynamic>{invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:22:16: Error: Can't spread a value with static type 'Null'.
   var m5 = {...n3, n1: n1};
@@ -227,17 +227,17 @@
       core::Iterator<core::MapEntry<Never, Never>> :sync-for-iterator = #t34{core::Map<Never, Never>}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<Never, Never> #t35 = :sync-for-iterator.{core::Iterator::current};
-        #t33.{core::Map::[]=}(#t35.{core::MapEntry::key}, #t35.{core::MapEntry::value});
+        #t33.{core::Map::[]=}{Invariant}(#t35.{core::MapEntry::key}, #t35.{core::MapEntry::value});
       }
     }
-    #t33.{core::Map::[]=}(n1, n1);
+    #t33.{core::Map::[]=}{Invariant}(n1, n1);
   } =>#t33;
 }
 static method test2<N1 extends Never = Never, N2 extends Never? = Never?, N3 extends Null = Null>(self::test2::N1 n1, self::test2::N2% n2, self::test2::N3% n3) → dynamic {
   core::List<Never> l1 = block {
     final core::List<Never> #t36 = <Never>[];
     for (final Never #t37 in n1)
-      #t36.{core::List::add}(#t37);
+      #t36.{core::List::add}{Invariant}(#t37);
   } =>#t36;
   core::List<Never> l2 = block {
     final core::List<Never> #t38 = <Never>[];
@@ -246,7 +246,7 @@
       core::Iterator<Never> :sync-for-iterator = #t39{core::Iterable<Never>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final Never #t40 = :sync-for-iterator.{core::Iterator::current};
-        #t38.{core::List::add}(#t40);
+        #t38.{core::List::add}{Invariant}(#t40);
       }
     }
   } =>#t38;
@@ -260,7 +260,7 @@
       core::Iterator<Never> :sync-for-iterator = #t42{core::Iterable<Never>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final Never #t43 = :sync-for-iterator.{core::Iterator::current};
-        #t41.{core::List::add}(#t43);
+        #t41.{core::List::add}{Invariant}(#t43);
       }
     }
   } =>#t41;
@@ -274,15 +274,15 @@
       core::Iterator<Never> :sync-for-iterator = #t45{core::Iterable<Never>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final Never #t46 = :sync-for-iterator.{core::Iterator::current};
-        #t44.{core::List::add}(#t46);
+        #t44.{core::List::add}{Invariant}(#t46);
       }
     }
   } =>#t44;
   core::Set<self::test2::N1> s1 = block {
     final core::Set<self::test2::N1> #t47 = new col::_CompactLinkedHashSet::•<self::test2::N1>();
     for (final self::test2::N1 #t48 in n1)
-      #t47.{core::Set::add}(#t48);
-    #t47.{core::Set::add}(n1);
+      #t47.{core::Set::add}{Invariant}(#t48);
+    #t47.{core::Set::add}{Invariant}(n1);
   } =>#t47;
   core::Set<self::test2::N1> s2 = block {
     final core::Set<self::test2::N1> #t49 = new col::_CompactLinkedHashSet::•<self::test2::N1>();
@@ -291,17 +291,17 @@
       core::Iterator<self::test2::N1> :sync-for-iterator = #t50{core::Iterable<self::test2::N1>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final self::test2::N1 #t51 = :sync-for-iterator.{core::Iterator::current};
-        #t49.{core::Set::add}(#t51);
+        #t49.{core::Set::add}{Invariant}(#t51);
       }
     }
-    #t49.{core::Set::add}(n1);
+    #t49.{core::Set::add}{Invariant}(n1);
   } =>#t49;
   core::Set<dynamic> s3 = block {
     final core::Set<dynamic> #t52 = new col::_CompactLinkedHashSet::•<dynamic>();
-    #t52.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:36:16: Error: Can't spread a value with static type 'N2'.
+    #t52.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:36:16: Error: Can't spread a value with static type 'N2'.
   var s3 = {...n2, n1};
                ^");
-    #t52.{core::Set::add}(n1);
+    #t52.{core::Set::add}{Invariant}(n1);
   } =>#t52;
   core::Set<self::test2::N1> s4 = block {
     final core::Set<self::test2::N1> #t53 = new col::_CompactLinkedHashSet::•<self::test2::N1>();
@@ -310,17 +310,17 @@
       core::Iterator<self::test2::N1> :sync-for-iterator = #t54{core::Iterable<self::test2::N1>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final self::test2::N1 #t55 = :sync-for-iterator.{core::Iterator::current};
-        #t53.{core::Set::add}(#t55);
+        #t53.{core::Set::add}{Invariant}(#t55);
       }
     }
-    #t53.{core::Set::add}(n1);
+    #t53.{core::Set::add}{Invariant}(n1);
   } =>#t53;
   core::Set<dynamic> s5 = block {
     final core::Set<dynamic> #t56 = new col::_CompactLinkedHashSet::•<dynamic>();
-    #t56.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:38:16: Error: Can't spread a value with static type 'N3'.
+    #t56.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:38:16: Error: Can't spread a value with static type 'N3'.
   var s5 = {...n3, n1};
                ^");
-    #t56.{core::Set::add}(n1);
+    #t56.{core::Set::add}{Invariant}(n1);
   } =>#t56;
   core::Set<self::test2::N1> s6 = block {
     final core::Set<self::test2::N1> #t57 = new col::_CompactLinkedHashSet::•<self::test2::N1>();
@@ -329,10 +329,10 @@
       core::Iterator<self::test2::N1> :sync-for-iterator = #t58{core::Iterable<self::test2::N1>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final self::test2::N1 #t59 = :sync-for-iterator.{core::Iterator::current};
-        #t57.{core::Set::add}(#t59);
+        #t57.{core::Set::add}{Invariant}(#t59);
       }
     }
-    #t57.{core::Set::add}(n1);
+    #t57.{core::Set::add}{Invariant}(n1);
   } =>#t57;
   core::Map<self::test2::N1, self::test2::N1> m1 = block {
     final core::Map<self::test2::N1, self::test2::N1> #t60 = <self::test2::N1, self::test2::N1>{};
@@ -340,10 +340,10 @@
       core::Iterator<core::MapEntry<<BottomType>, <BottomType>>> :sync-for-iterator = n1.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<self::test2::N1, self::test2::N1> #t61 = :sync-for-iterator.{core::Iterator::current};
-        #t60.{core::Map::[]=}(#t61.{core::MapEntry::key}, #t61.{core::MapEntry::value});
+        #t60.{core::Map::[]=}{Invariant}(#t61.{core::MapEntry::key}, #t61.{core::MapEntry::value});
       }
     }
-    #t60.{core::Map::[]=}(n1, n1);
+    #t60.{core::Map::[]=}{Invariant}(n1, n1);
   } =>#t60;
   core::Map<self::test2::N1, self::test2::N1> m2 = block {
     final core::Map<self::test2::N1, self::test2::N1> #t62 = <self::test2::N1, self::test2::N1>{};
@@ -352,10 +352,10 @@
       core::Iterator<core::MapEntry<self::test2::N1, self::test2::N1>> :sync-for-iterator = #t63{core::Map<self::test2::N1, self::test2::N1>}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<self::test2::N1, self::test2::N1> #t64 = :sync-for-iterator.{core::Iterator::current};
-        #t62.{core::Map::[]=}(#t64.{core::MapEntry::key}, #t64.{core::MapEntry::value});
+        #t62.{core::Map::[]=}{Invariant}(#t64.{core::MapEntry::key}, #t64.{core::MapEntry::value});
       }
     }
-    #t62.{core::Map::[]=}(n1, n1);
+    #t62.{core::Map::[]=}{Invariant}(n1, n1);
   } =>#t62;
   core::Map<dynamic, dynamic> m3 = <dynamic, dynamic>{invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:42:16: Error: Can't spread a value with static type 'N2'.
   var m3 = {...n2, n1: n1};
@@ -367,10 +367,10 @@
       core::Iterator<core::MapEntry<self::test2::N1, self::test2::N1>> :sync-for-iterator = #t66{core::Map<self::test2::N1, self::test2::N1>}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<self::test2::N1, self::test2::N1> #t67 = :sync-for-iterator.{core::Iterator::current};
-        #t65.{core::Map::[]=}(#t67.{core::MapEntry::key}, #t67.{core::MapEntry::value});
+        #t65.{core::Map::[]=}{Invariant}(#t67.{core::MapEntry::key}, #t67.{core::MapEntry::value});
       }
     }
-    #t65.{core::Map::[]=}(n1, n1);
+    #t65.{core::Map::[]=}{Invariant}(n1, n1);
   } =>#t65;
   core::Map<dynamic, dynamic> m5 = <dynamic, dynamic>{invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:44:16: Error: Can't spread a value with static type 'N3'.
   var m5 = {...n3, n1: n1};
@@ -382,10 +382,10 @@
       core::Iterator<core::MapEntry<self::test2::N1, self::test2::N1>> :sync-for-iterator = #t69{core::Map<self::test2::N1, self::test2::N1>}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<self::test2::N1, self::test2::N1> #t70 = :sync-for-iterator.{core::Iterator::current};
-        #t68.{core::Map::[]=}(#t70.{core::MapEntry::key}, #t70.{core::MapEntry::value});
+        #t68.{core::Map::[]=}{Invariant}(#t70.{core::MapEntry::key}, #t70.{core::MapEntry::value});
       }
     }
-    #t68.{core::Map::[]=}(n1, n1);
+    #t68.{core::Map::[]=}{Invariant}(n1, n1);
   } =>#t68;
 }
 static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/issue42758.dart.weak.expect b/pkg/front_end/testcases/nnbd/issue42758.dart.weak.expect
index db1601c..5672439 100644
--- a/pkg/front_end/testcases/nnbd/issue42758.dart.weak.expect
+++ b/pkg/front_end/testcases/nnbd/issue42758.dart.weak.expect
@@ -83,14 +83,14 @@
   core::List<Never> l1 = block {
     final core::List<Never> #t1 = <Never>[];
     for (final Never #t2 in let final Never #t3 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."))
-      #t1.{core::List::add}(#t2);
+      #t1.{core::List::add}{Invariant}(#t2);
   } =>#t1;
   core::List<Never> l2 = block {
     final core::List<Never> #t4 = <Never>[];
     final core::Iterable<Never>? #t5 = let final Never #t6 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`.");
     if(!#t5.{core::Object::==}(null))
       for (final Never #t7 in #t5{core::Iterable<Never>})
-        #t4.{core::List::add}(#t7);
+        #t4.{core::List::add}{Invariant}(#t7);
   } =>#t4;
   core::List<dynamic> l3 = <dynamic>[invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:8:16: Error: Can't spread a value with static type 'Never?'.
   var l3 = [...n2];
@@ -100,7 +100,7 @@
     final core::Iterable<Never>? #t9 = n2;
     if(!#t9.{core::Object::==}(null))
       for (final Never #t10 in #t9{core::Iterable<Never>})
-        #t8.{core::List::add}(#t10);
+        #t8.{core::List::add}{Invariant}(#t10);
   } =>#t8;
   core::List<dynamic> l5 = <dynamic>[invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:10:16: Error: Can't spread a value with static type 'Null'.
   var l5 = [...n3];
@@ -110,65 +110,65 @@
     final core::Iterable<Never>? #t12 = n3;
     if(!#t12.{core::Object::==}(null))
       for (final Never #t13 in #t12{core::Iterable<Never>})
-        #t11.{core::List::add}(#t13);
+        #t11.{core::List::add}{Invariant}(#t13);
   } =>#t11;
   core::Set<Never> s1 = block {
     final core::Set<Never> #t14 = col::LinkedHashSet::•<Never>();
     for (final Never #t15 in let final Never #t16 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."))
-      #t14.{core::Set::add}(#t15);
-    #t14.{core::Set::add}(let final Never #t17 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+      #t14.{core::Set::add}{Invariant}(#t15);
+    #t14.{core::Set::add}{Invariant}(let final Never #t17 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t14;
   core::Set<Never> s2 = block {
     final core::Set<Never> #t18 = col::LinkedHashSet::•<Never>();
     final core::Iterable<Never>? #t19 = let final Never #t20 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`.");
     if(!#t19.{core::Object::==}(null))
       for (final Never #t21 in #t19{core::Iterable<Never>})
-        #t18.{core::Set::add}(#t21);
-    #t18.{core::Set::add}(let final Never #t22 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+        #t18.{core::Set::add}{Invariant}(#t21);
+    #t18.{core::Set::add}{Invariant}(let final Never #t22 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t18;
   core::Set<dynamic> s3 = block {
     final core::Set<dynamic> #t23 = col::LinkedHashSet::•<dynamic>();
-    #t23.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:14:16: Error: Can't spread a value with static type 'Never?'.
+    #t23.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:14:16: Error: Can't spread a value with static type 'Never?'.
   var s3 = {...n2, n1};
                ^");
-    #t23.{core::Set::add}(let final Never #t24 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+    #t23.{core::Set::add}{Invariant}(let final Never #t24 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t23;
   core::Set<Never> s4 = block {
     final core::Set<Never> #t25 = col::LinkedHashSet::•<Never>();
     final core::Iterable<Never>? #t26 = n2;
     if(!#t26.{core::Object::==}(null))
       for (final Never #t27 in #t26{core::Iterable<Never>})
-        #t25.{core::Set::add}(#t27);
-    #t25.{core::Set::add}(let final Never #t28 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+        #t25.{core::Set::add}{Invariant}(#t27);
+    #t25.{core::Set::add}{Invariant}(let final Never #t28 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t25;
   core::Set<dynamic> s5 = block {
     final core::Set<dynamic> #t29 = col::LinkedHashSet::•<dynamic>();
-    #t29.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:16:16: Error: Can't spread a value with static type 'Null'.
+    #t29.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:16:16: Error: Can't spread a value with static type 'Null'.
   var s5 = {...n3, n1};
                ^");
-    #t29.{core::Set::add}(let final Never #t30 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+    #t29.{core::Set::add}{Invariant}(let final Never #t30 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t29;
   core::Set<Never> s6 = block {
     final core::Set<Never> #t31 = col::LinkedHashSet::•<Never>();
     final core::Iterable<Never>? #t32 = n3;
     if(!#t32.{core::Object::==}(null))
       for (final Never #t33 in #t32{core::Iterable<Never>})
-        #t31.{core::Set::add}(#t33);
-    #t31.{core::Set::add}(let final Never #t34 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+        #t31.{core::Set::add}{Invariant}(#t33);
+    #t31.{core::Set::add}{Invariant}(let final Never #t34 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t31;
   core::Map<Never, Never> m1 = block {
     final core::Map<Never, Never> #t35 = <Never, Never>{};
     for (final core::MapEntry<Never, Never> #t36 in (let final Never #t37 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`.")).{core::Map::entries})
-      #t35.{core::Map::[]=}(#t36.{core::MapEntry::key}, #t36.{core::MapEntry::value});
-    #t35.{core::Map::[]=}(let final Never #t38 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final Never #t39 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+      #t35.{core::Map::[]=}{Invariant}(#t36.{core::MapEntry::key}, #t36.{core::MapEntry::value});
+    #t35.{core::Map::[]=}{Invariant}(let final Never #t38 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final Never #t39 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t35;
   core::Map<Never, Never> m2 = block {
     final core::Map<Never, Never> #t40 = <Never, Never>{};
     final core::Map<Never, Never>? #t41 = let final Never #t42 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`.");
     if(!#t41.{core::Object::==}(null))
       for (final core::MapEntry<Never, Never> #t43 in #t41{core::Map<Never, Never>}.{core::Map::entries})
-        #t40.{core::Map::[]=}(#t43.{core::MapEntry::key}, #t43.{core::MapEntry::value});
-    #t40.{core::Map::[]=}(let final Never #t44 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final Never #t45 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+        #t40.{core::Map::[]=}{Invariant}(#t43.{core::MapEntry::key}, #t43.{core::MapEntry::value});
+    #t40.{core::Map::[]=}{Invariant}(let final Never #t44 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final Never #t45 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t40;
   core::Map<dynamic, dynamic> m3 = <dynamic, dynamic>{invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:20:16: Error: Can't spread a value with static type 'Never?'.
   var m3 = {...n2, n1: n1};
@@ -178,8 +178,8 @@
     final core::Map<Never, Never>? #t49 = n2;
     if(!#t49.{core::Object::==}(null))
       for (final core::MapEntry<Never, Never> #t50 in #t49{core::Map<Never, Never>}.{core::Map::entries})
-        #t48.{core::Map::[]=}(#t50.{core::MapEntry::key}, #t50.{core::MapEntry::value});
-    #t48.{core::Map::[]=}(let final Never #t51 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final Never #t52 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+        #t48.{core::Map::[]=}{Invariant}(#t50.{core::MapEntry::key}, #t50.{core::MapEntry::value});
+    #t48.{core::Map::[]=}{Invariant}(let final Never #t51 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final Never #t52 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t48;
   core::Map<dynamic, dynamic> m5 = <dynamic, dynamic>{invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:22:16: Error: Can't spread a value with static type 'Null'.
   var m5 = {...n3, n1: n1};
@@ -189,22 +189,22 @@
     final core::Map<Never, Never>? #t56 = n3;
     if(!#t56.{core::Object::==}(null))
       for (final core::MapEntry<Never, Never> #t57 in #t56{core::Map<Never, Never>}.{core::Map::entries})
-        #t55.{core::Map::[]=}(#t57.{core::MapEntry::key}, #t57.{core::MapEntry::value});
-    #t55.{core::Map::[]=}(let final Never #t58 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final Never #t59 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+        #t55.{core::Map::[]=}{Invariant}(#t57.{core::MapEntry::key}, #t57.{core::MapEntry::value});
+    #t55.{core::Map::[]=}{Invariant}(let final Never #t58 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final Never #t59 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t55;
 }
 static method test2<N1 extends Never = Never, N2 extends Never? = Never?, N3 extends Null = Null>(self::test2::N1 n1, self::test2::N2% n2, self::test2::N3% n3) → dynamic {
   core::List<Never> l1 = block {
     final core::List<Never> #t60 = <Never>[];
     for (final Never #t61 in let final self::test2::N1 #t62 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."))
-      #t60.{core::List::add}(#t61);
+      #t60.{core::List::add}{Invariant}(#t61);
   } =>#t60;
   core::List<Never> l2 = block {
     final core::List<Never> #t63 = <Never>[];
     final core::Iterable<Never>? #t64 = let final self::test2::N1 #t65 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`.");
     if(!#t64.{core::Object::==}(null))
       for (final Never #t66 in #t64{core::Iterable<Never>})
-        #t63.{core::List::add}(#t66);
+        #t63.{core::List::add}{Invariant}(#t66);
   } =>#t63;
   core::List<dynamic> l3 = <dynamic>[invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:30:16: Error: Can't spread a value with static type 'N2'.
   var l3 = [...n2];
@@ -214,7 +214,7 @@
     final core::Iterable<Never>? #t68 = n2;
     if(!#t68.{core::Object::==}(null))
       for (final Never #t69 in #t68{core::Iterable<Never>})
-        #t67.{core::List::add}(#t69);
+        #t67.{core::List::add}{Invariant}(#t69);
   } =>#t67;
   core::List<dynamic> l5 = <dynamic>[invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:32:16: Error: Can't spread a value with static type 'N3'.
   var l5 = [...n3];
@@ -224,65 +224,65 @@
     final core::Iterable<Never>? #t71 = n3;
     if(!#t71.{core::Object::==}(null))
       for (final Never #t72 in #t71{core::Iterable<Never>})
-        #t70.{core::List::add}(#t72);
+        #t70.{core::List::add}{Invariant}(#t72);
   } =>#t70;
   core::Set<self::test2::N1> s1 = block {
     final core::Set<self::test2::N1> #t73 = col::LinkedHashSet::•<self::test2::N1>();
     for (final self::test2::N1 #t74 in let final self::test2::N1 #t75 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."))
-      #t73.{core::Set::add}(#t74);
-    #t73.{core::Set::add}(let final self::test2::N1 #t76 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+      #t73.{core::Set::add}{Invariant}(#t74);
+    #t73.{core::Set::add}{Invariant}(let final self::test2::N1 #t76 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t73;
   core::Set<self::test2::N1> s2 = block {
     final core::Set<self::test2::N1> #t77 = col::LinkedHashSet::•<self::test2::N1>();
     final core::Iterable<self::test2::N1>? #t78 = let final self::test2::N1 #t79 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`.");
     if(!#t78.{core::Object::==}(null))
       for (final self::test2::N1 #t80 in #t78{core::Iterable<self::test2::N1>})
-        #t77.{core::Set::add}(#t80);
-    #t77.{core::Set::add}(let final self::test2::N1 #t81 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+        #t77.{core::Set::add}{Invariant}(#t80);
+    #t77.{core::Set::add}{Invariant}(let final self::test2::N1 #t81 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t77;
   core::Set<dynamic> s3 = block {
     final core::Set<dynamic> #t82 = col::LinkedHashSet::•<dynamic>();
-    #t82.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:36:16: Error: Can't spread a value with static type 'N2'.
+    #t82.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:36:16: Error: Can't spread a value with static type 'N2'.
   var s3 = {...n2, n1};
                ^");
-    #t82.{core::Set::add}(let final self::test2::N1 #t83 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+    #t82.{core::Set::add}{Invariant}(let final self::test2::N1 #t83 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t82;
   core::Set<self::test2::N1> s4 = block {
     final core::Set<self::test2::N1> #t84 = col::LinkedHashSet::•<self::test2::N1>();
     final core::Iterable<self::test2::N1>? #t85 = n2;
     if(!#t85.{core::Object::==}(null))
       for (final self::test2::N1 #t86 in #t85{core::Iterable<self::test2::N1>})
-        #t84.{core::Set::add}(#t86);
-    #t84.{core::Set::add}(let final self::test2::N1 #t87 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+        #t84.{core::Set::add}{Invariant}(#t86);
+    #t84.{core::Set::add}{Invariant}(let final self::test2::N1 #t87 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t84;
   core::Set<dynamic> s5 = block {
     final core::Set<dynamic> #t88 = col::LinkedHashSet::•<dynamic>();
-    #t88.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:38:16: Error: Can't spread a value with static type 'N3'.
+    #t88.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:38:16: Error: Can't spread a value with static type 'N3'.
   var s5 = {...n3, n1};
                ^");
-    #t88.{core::Set::add}(let final self::test2::N1 #t89 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+    #t88.{core::Set::add}{Invariant}(let final self::test2::N1 #t89 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t88;
   core::Set<self::test2::N1> s6 = block {
     final core::Set<self::test2::N1> #t90 = col::LinkedHashSet::•<self::test2::N1>();
     final core::Iterable<self::test2::N1>? #t91 = n3;
     if(!#t91.{core::Object::==}(null))
       for (final self::test2::N1 #t92 in #t91{core::Iterable<self::test2::N1>})
-        #t90.{core::Set::add}(#t92);
-    #t90.{core::Set::add}(let final self::test2::N1 #t93 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+        #t90.{core::Set::add}{Invariant}(#t92);
+    #t90.{core::Set::add}{Invariant}(let final self::test2::N1 #t93 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t90;
   core::Map<self::test2::N1, self::test2::N1> m1 = block {
     final core::Map<self::test2::N1, self::test2::N1> #t94 = <self::test2::N1, self::test2::N1>{};
     for (final core::MapEntry<self::test2::N1, self::test2::N1> #t95 in (let final self::test2::N1 #t96 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`.")).{core::Map::entries})
-      #t94.{core::Map::[]=}(#t95.{core::MapEntry::key}, #t95.{core::MapEntry::value});
-    #t94.{core::Map::[]=}(let final self::test2::N1 #t97 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final self::test2::N1 #t98 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+      #t94.{core::Map::[]=}{Invariant}(#t95.{core::MapEntry::key}, #t95.{core::MapEntry::value});
+    #t94.{core::Map::[]=}{Invariant}(let final self::test2::N1 #t97 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final self::test2::N1 #t98 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t94;
   core::Map<self::test2::N1, self::test2::N1> m2 = block {
     final core::Map<self::test2::N1, self::test2::N1> #t99 = <self::test2::N1, self::test2::N1>{};
     final core::Map<self::test2::N1, self::test2::N1>? #t100 = let final self::test2::N1 #t101 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`.");
     if(!#t100.{core::Object::==}(null))
       for (final core::MapEntry<self::test2::N1, self::test2::N1> #t102 in #t100{core::Map<self::test2::N1, self::test2::N1>}.{core::Map::entries})
-        #t99.{core::Map::[]=}(#t102.{core::MapEntry::key}, #t102.{core::MapEntry::value});
-    #t99.{core::Map::[]=}(let final self::test2::N1 #t103 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final self::test2::N1 #t104 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+        #t99.{core::Map::[]=}{Invariant}(#t102.{core::MapEntry::key}, #t102.{core::MapEntry::value});
+    #t99.{core::Map::[]=}{Invariant}(let final self::test2::N1 #t103 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final self::test2::N1 #t104 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t99;
   core::Map<dynamic, dynamic> m3 = <dynamic, dynamic>{invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:42:16: Error: Can't spread a value with static type 'N2'.
   var m3 = {...n2, n1: n1};
@@ -292,8 +292,8 @@
     final core::Map<self::test2::N1, self::test2::N1>? #t108 = n2;
     if(!#t108.{core::Object::==}(null))
       for (final core::MapEntry<self::test2::N1, self::test2::N1> #t109 in #t108{core::Map<self::test2::N1, self::test2::N1>}.{core::Map::entries})
-        #t107.{core::Map::[]=}(#t109.{core::MapEntry::key}, #t109.{core::MapEntry::value});
-    #t107.{core::Map::[]=}(let final self::test2::N1 #t110 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final self::test2::N1 #t111 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+        #t107.{core::Map::[]=}{Invariant}(#t109.{core::MapEntry::key}, #t109.{core::MapEntry::value});
+    #t107.{core::Map::[]=}{Invariant}(let final self::test2::N1 #t110 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final self::test2::N1 #t111 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t107;
   core::Map<dynamic, dynamic> m5 = <dynamic, dynamic>{invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:44:16: Error: Can't spread a value with static type 'N3'.
   var m5 = {...n3, n1: n1};
@@ -303,8 +303,8 @@
     final core::Map<self::test2::N1, self::test2::N1>? #t115 = n3;
     if(!#t115.{core::Object::==}(null))
       for (final core::MapEntry<self::test2::N1, self::test2::N1> #t116 in #t115{core::Map<self::test2::N1, self::test2::N1>}.{core::Map::entries})
-        #t114.{core::Map::[]=}(#t116.{core::MapEntry::key}, #t116.{core::MapEntry::value});
-    #t114.{core::Map::[]=}(let final self::test2::N1 #t117 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final self::test2::N1 #t118 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+        #t114.{core::Map::[]=}{Invariant}(#t116.{core::MapEntry::key}, #t116.{core::MapEntry::value});
+    #t114.{core::Map::[]=}{Invariant}(let final self::test2::N1 #t117 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final self::test2::N1 #t118 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t114;
 }
 static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/issue42758.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd/issue42758.dart.weak.transformed.expect
index a2689d6..3c95716 100644
--- a/pkg/front_end/testcases/nnbd/issue42758.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/nnbd/issue42758.dart.weak.transformed.expect
@@ -83,7 +83,7 @@
   core::List<Never> l1 = block {
     final core::List<Never> #t1 = <Never>[];
     for (final Never #t2 in let final Never #t3 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."))
-      #t1.{core::List::add}(#t2);
+      #t1.{core::List::add}{Invariant}(#t2);
   } =>#t1;
   core::List<Never> l2 = block {
     final core::List<Never> #t4 = <Never>[];
@@ -92,7 +92,7 @@
       core::Iterator<Never> :sync-for-iterator = #t5{core::Iterable<Never>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final Never #t7 = :sync-for-iterator.{core::Iterator::current};
-        #t4.{core::List::add}(#t7);
+        #t4.{core::List::add}{Invariant}(#t7);
       }
     }
   } =>#t4;
@@ -106,7 +106,7 @@
       core::Iterator<Never> :sync-for-iterator = #t9{core::Iterable<Never>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final Never #t10 = :sync-for-iterator.{core::Iterator::current};
-        #t8.{core::List::add}(#t10);
+        #t8.{core::List::add}{Invariant}(#t10);
       }
     }
   } =>#t8;
@@ -120,15 +120,15 @@
       core::Iterator<Never> :sync-for-iterator = #t12{core::Iterable<Never>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final Never #t13 = :sync-for-iterator.{core::Iterator::current};
-        #t11.{core::List::add}(#t13);
+        #t11.{core::List::add}{Invariant}(#t13);
       }
     }
   } =>#t11;
   core::Set<Never> s1 = block {
     final core::Set<Never> #t14 = new col::_CompactLinkedHashSet::•<Never>();
     for (final Never #t15 in let final Never #t16 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."))
-      #t14.{core::Set::add}(#t15);
-    #t14.{core::Set::add}(let final Never #t17 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+      #t14.{core::Set::add}{Invariant}(#t15);
+    #t14.{core::Set::add}{Invariant}(let final Never #t17 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t14;
   core::Set<Never> s2 = block {
     final core::Set<Never> #t18 = new col::_CompactLinkedHashSet::•<Never>();
@@ -137,17 +137,17 @@
       core::Iterator<Never> :sync-for-iterator = #t19{core::Iterable<Never>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final Never #t21 = :sync-for-iterator.{core::Iterator::current};
-        #t18.{core::Set::add}(#t21);
+        #t18.{core::Set::add}{Invariant}(#t21);
       }
     }
-    #t18.{core::Set::add}(let final Never #t22 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+    #t18.{core::Set::add}{Invariant}(let final Never #t22 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t18;
   core::Set<dynamic> s3 = block {
     final core::Set<dynamic> #t23 = new col::_CompactLinkedHashSet::•<dynamic>();
-    #t23.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:14:16: Error: Can't spread a value with static type 'Never?'.
+    #t23.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:14:16: Error: Can't spread a value with static type 'Never?'.
   var s3 = {...n2, n1};
                ^");
-    #t23.{core::Set::add}(let final Never #t24 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+    #t23.{core::Set::add}{Invariant}(let final Never #t24 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t23;
   core::Set<Never> s4 = block {
     final core::Set<Never> #t25 = new col::_CompactLinkedHashSet::•<Never>();
@@ -156,17 +156,17 @@
       core::Iterator<Never> :sync-for-iterator = #t26{core::Iterable<Never>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final Never #t27 = :sync-for-iterator.{core::Iterator::current};
-        #t25.{core::Set::add}(#t27);
+        #t25.{core::Set::add}{Invariant}(#t27);
       }
     }
-    #t25.{core::Set::add}(let final Never #t28 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+    #t25.{core::Set::add}{Invariant}(let final Never #t28 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t25;
   core::Set<dynamic> s5 = block {
     final core::Set<dynamic> #t29 = new col::_CompactLinkedHashSet::•<dynamic>();
-    #t29.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:16:16: Error: Can't spread a value with static type 'Null'.
+    #t29.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:16:16: Error: Can't spread a value with static type 'Null'.
   var s5 = {...n3, n1};
                ^");
-    #t29.{core::Set::add}(let final Never #t30 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+    #t29.{core::Set::add}{Invariant}(let final Never #t30 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t29;
   core::Set<Never> s6 = block {
     final core::Set<Never> #t31 = new col::_CompactLinkedHashSet::•<Never>();
@@ -175,10 +175,10 @@
       core::Iterator<Never> :sync-for-iterator = #t32{core::Iterable<Never>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final Never #t33 = :sync-for-iterator.{core::Iterator::current};
-        #t31.{core::Set::add}(#t33);
+        #t31.{core::Set::add}{Invariant}(#t33);
       }
     }
-    #t31.{core::Set::add}(let final Never #t34 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+    #t31.{core::Set::add}{Invariant}(let final Never #t34 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t31;
   core::Map<Never, Never> m1 = block {
     final core::Map<Never, Never> #t35 = <Never, Never>{};
@@ -186,10 +186,10 @@
       core::Iterator<core::MapEntry<<BottomType>, <BottomType>>> :sync-for-iterator = (let final Never #t36 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`.")).{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<Never, Never> #t37 = :sync-for-iterator.{core::Iterator::current};
-        #t35.{core::Map::[]=}(#t37.{core::MapEntry::key}, #t37.{core::MapEntry::value});
+        #t35.{core::Map::[]=}{Invariant}(#t37.{core::MapEntry::key}, #t37.{core::MapEntry::value});
       }
     }
-    #t35.{core::Map::[]=}(let final Never #t38 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final Never #t39 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+    #t35.{core::Map::[]=}{Invariant}(let final Never #t38 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final Never #t39 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t35;
   core::Map<Never, Never> m2 = block {
     final core::Map<Never, Never> #t40 = <Never, Never>{};
@@ -198,10 +198,10 @@
       core::Iterator<core::MapEntry<Never, Never>> :sync-for-iterator = #t41{core::Map<Never, Never>}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<Never, Never> #t43 = :sync-for-iterator.{core::Iterator::current};
-        #t40.{core::Map::[]=}(#t43.{core::MapEntry::key}, #t43.{core::MapEntry::value});
+        #t40.{core::Map::[]=}{Invariant}(#t43.{core::MapEntry::key}, #t43.{core::MapEntry::value});
       }
     }
-    #t40.{core::Map::[]=}(let final Never #t44 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final Never #t45 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+    #t40.{core::Map::[]=}{Invariant}(let final Never #t44 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final Never #t45 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t40;
   core::Map<dynamic, dynamic> m3 = <dynamic, dynamic>{invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:20:16: Error: Can't spread a value with static type 'Never?'.
   var m3 = {...n2, n1: n1};
@@ -213,10 +213,10 @@
       core::Iterator<core::MapEntry<Never, Never>> :sync-for-iterator = #t49{core::Map<Never, Never>}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<Never, Never> #t50 = :sync-for-iterator.{core::Iterator::current};
-        #t48.{core::Map::[]=}(#t50.{core::MapEntry::key}, #t50.{core::MapEntry::value});
+        #t48.{core::Map::[]=}{Invariant}(#t50.{core::MapEntry::key}, #t50.{core::MapEntry::value});
       }
     }
-    #t48.{core::Map::[]=}(let final Never #t51 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final Never #t52 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+    #t48.{core::Map::[]=}{Invariant}(let final Never #t51 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final Never #t52 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t48;
   core::Map<dynamic, dynamic> m5 = <dynamic, dynamic>{invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:22:16: Error: Can't spread a value with static type 'Null'.
   var m5 = {...n3, n1: n1};
@@ -228,17 +228,17 @@
       core::Iterator<core::MapEntry<Never, Never>> :sync-for-iterator = #t56{core::Map<Never, Never>}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<Never, Never> #t57 = :sync-for-iterator.{core::Iterator::current};
-        #t55.{core::Map::[]=}(#t57.{core::MapEntry::key}, #t57.{core::MapEntry::value});
+        #t55.{core::Map::[]=}{Invariant}(#t57.{core::MapEntry::key}, #t57.{core::MapEntry::value});
       }
     }
-    #t55.{core::Map::[]=}(let final Never #t58 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final Never #t59 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+    #t55.{core::Map::[]=}{Invariant}(let final Never #t58 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final Never #t59 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t55;
 }
 static method test2<N1 extends Never = Never, N2 extends Never? = Never?, N3 extends Null = Null>(self::test2::N1 n1, self::test2::N2% n2, self::test2::N3% n3) → dynamic {
   core::List<Never> l1 = block {
     final core::List<Never> #t60 = <Never>[];
     for (final Never #t61 in let final self::test2::N1 #t62 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."))
-      #t60.{core::List::add}(#t61);
+      #t60.{core::List::add}{Invariant}(#t61);
   } =>#t60;
   core::List<Never> l2 = block {
     final core::List<Never> #t63 = <Never>[];
@@ -247,7 +247,7 @@
       core::Iterator<Never> :sync-for-iterator = #t64{core::Iterable<Never>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final Never #t66 = :sync-for-iterator.{core::Iterator::current};
-        #t63.{core::List::add}(#t66);
+        #t63.{core::List::add}{Invariant}(#t66);
       }
     }
   } =>#t63;
@@ -261,7 +261,7 @@
       core::Iterator<Never> :sync-for-iterator = #t68{core::Iterable<Never>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final Never #t69 = :sync-for-iterator.{core::Iterator::current};
-        #t67.{core::List::add}(#t69);
+        #t67.{core::List::add}{Invariant}(#t69);
       }
     }
   } =>#t67;
@@ -275,15 +275,15 @@
       core::Iterator<Never> :sync-for-iterator = #t71{core::Iterable<Never>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final Never #t72 = :sync-for-iterator.{core::Iterator::current};
-        #t70.{core::List::add}(#t72);
+        #t70.{core::List::add}{Invariant}(#t72);
       }
     }
   } =>#t70;
   core::Set<self::test2::N1> s1 = block {
     final core::Set<self::test2::N1> #t73 = new col::_CompactLinkedHashSet::•<self::test2::N1>();
     for (final self::test2::N1 #t74 in let final self::test2::N1 #t75 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."))
-      #t73.{core::Set::add}(#t74);
-    #t73.{core::Set::add}(let final self::test2::N1 #t76 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+      #t73.{core::Set::add}{Invariant}(#t74);
+    #t73.{core::Set::add}{Invariant}(let final self::test2::N1 #t76 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t73;
   core::Set<self::test2::N1> s2 = block {
     final core::Set<self::test2::N1> #t77 = new col::_CompactLinkedHashSet::•<self::test2::N1>();
@@ -292,17 +292,17 @@
       core::Iterator<self::test2::N1> :sync-for-iterator = #t78{core::Iterable<self::test2::N1>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final self::test2::N1 #t80 = :sync-for-iterator.{core::Iterator::current};
-        #t77.{core::Set::add}(#t80);
+        #t77.{core::Set::add}{Invariant}(#t80);
       }
     }
-    #t77.{core::Set::add}(let final self::test2::N1 #t81 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+    #t77.{core::Set::add}{Invariant}(let final self::test2::N1 #t81 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t77;
   core::Set<dynamic> s3 = block {
     final core::Set<dynamic> #t82 = new col::_CompactLinkedHashSet::•<dynamic>();
-    #t82.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:36:16: Error: Can't spread a value with static type 'N2'.
+    #t82.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:36:16: Error: Can't spread a value with static type 'N2'.
   var s3 = {...n2, n1};
                ^");
-    #t82.{core::Set::add}(let final self::test2::N1 #t83 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+    #t82.{core::Set::add}{Invariant}(let final self::test2::N1 #t83 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t82;
   core::Set<self::test2::N1> s4 = block {
     final core::Set<self::test2::N1> #t84 = new col::_CompactLinkedHashSet::•<self::test2::N1>();
@@ -311,17 +311,17 @@
       core::Iterator<self::test2::N1> :sync-for-iterator = #t85{core::Iterable<self::test2::N1>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final self::test2::N1 #t86 = :sync-for-iterator.{core::Iterator::current};
-        #t84.{core::Set::add}(#t86);
+        #t84.{core::Set::add}{Invariant}(#t86);
       }
     }
-    #t84.{core::Set::add}(let final self::test2::N1 #t87 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+    #t84.{core::Set::add}{Invariant}(let final self::test2::N1 #t87 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t84;
   core::Set<dynamic> s5 = block {
     final core::Set<dynamic> #t88 = new col::_CompactLinkedHashSet::•<dynamic>();
-    #t88.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:38:16: Error: Can't spread a value with static type 'N3'.
+    #t88.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:38:16: Error: Can't spread a value with static type 'N3'.
   var s5 = {...n3, n1};
                ^");
-    #t88.{core::Set::add}(let final self::test2::N1 #t89 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+    #t88.{core::Set::add}{Invariant}(let final self::test2::N1 #t89 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t88;
   core::Set<self::test2::N1> s6 = block {
     final core::Set<self::test2::N1> #t90 = new col::_CompactLinkedHashSet::•<self::test2::N1>();
@@ -330,10 +330,10 @@
       core::Iterator<self::test2::N1> :sync-for-iterator = #t91{core::Iterable<self::test2::N1>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final self::test2::N1 #t92 = :sync-for-iterator.{core::Iterator::current};
-        #t90.{core::Set::add}(#t92);
+        #t90.{core::Set::add}{Invariant}(#t92);
       }
     }
-    #t90.{core::Set::add}(let final self::test2::N1 #t93 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+    #t90.{core::Set::add}{Invariant}(let final self::test2::N1 #t93 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t90;
   core::Map<self::test2::N1, self::test2::N1> m1 = block {
     final core::Map<self::test2::N1, self::test2::N1> #t94 = <self::test2::N1, self::test2::N1>{};
@@ -341,10 +341,10 @@
       core::Iterator<core::MapEntry<<BottomType>, <BottomType>>> :sync-for-iterator = (let final self::test2::N1 #t95 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`.")).{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<self::test2::N1, self::test2::N1> #t96 = :sync-for-iterator.{core::Iterator::current};
-        #t94.{core::Map::[]=}(#t96.{core::MapEntry::key}, #t96.{core::MapEntry::value});
+        #t94.{core::Map::[]=}{Invariant}(#t96.{core::MapEntry::key}, #t96.{core::MapEntry::value});
       }
     }
-    #t94.{core::Map::[]=}(let final self::test2::N1 #t97 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final self::test2::N1 #t98 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+    #t94.{core::Map::[]=}{Invariant}(let final self::test2::N1 #t97 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final self::test2::N1 #t98 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t94;
   core::Map<self::test2::N1, self::test2::N1> m2 = block {
     final core::Map<self::test2::N1, self::test2::N1> #t99 = <self::test2::N1, self::test2::N1>{};
@@ -353,10 +353,10 @@
       core::Iterator<core::MapEntry<self::test2::N1, self::test2::N1>> :sync-for-iterator = #t100{core::Map<self::test2::N1, self::test2::N1>}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<self::test2::N1, self::test2::N1> #t102 = :sync-for-iterator.{core::Iterator::current};
-        #t99.{core::Map::[]=}(#t102.{core::MapEntry::key}, #t102.{core::MapEntry::value});
+        #t99.{core::Map::[]=}{Invariant}(#t102.{core::MapEntry::key}, #t102.{core::MapEntry::value});
       }
     }
-    #t99.{core::Map::[]=}(let final self::test2::N1 #t103 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final self::test2::N1 #t104 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+    #t99.{core::Map::[]=}{Invariant}(let final self::test2::N1 #t103 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final self::test2::N1 #t104 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t99;
   core::Map<dynamic, dynamic> m3 = <dynamic, dynamic>{invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:42:16: Error: Can't spread a value with static type 'N2'.
   var m3 = {...n2, n1: n1};
@@ -368,10 +368,10 @@
       core::Iterator<core::MapEntry<self::test2::N1, self::test2::N1>> :sync-for-iterator = #t108{core::Map<self::test2::N1, self::test2::N1>}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<self::test2::N1, self::test2::N1> #t109 = :sync-for-iterator.{core::Iterator::current};
-        #t107.{core::Map::[]=}(#t109.{core::MapEntry::key}, #t109.{core::MapEntry::value});
+        #t107.{core::Map::[]=}{Invariant}(#t109.{core::MapEntry::key}, #t109.{core::MapEntry::value});
       }
     }
-    #t107.{core::Map::[]=}(let final self::test2::N1 #t110 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final self::test2::N1 #t111 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+    #t107.{core::Map::[]=}{Invariant}(let final self::test2::N1 #t110 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final self::test2::N1 #t111 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t107;
   core::Map<dynamic, dynamic> m5 = <dynamic, dynamic>{invalid-expression "pkg/front_end/testcases/nnbd/issue42758.dart:44:16: Error: Can't spread a value with static type 'N3'.
   var m5 = {...n3, n1: n1};
@@ -383,10 +383,10 @@
       core::Iterator<core::MapEntry<self::test2::N1, self::test2::N1>> :sync-for-iterator = #t115{core::Map<self::test2::N1, self::test2::N1>}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<self::test2::N1, self::test2::N1> #t116 = :sync-for-iterator.{core::Iterator::current};
-        #t114.{core::Map::[]=}(#t116.{core::MapEntry::key}, #t116.{core::MapEntry::value});
+        #t114.{core::Map::[]=}{Invariant}(#t116.{core::MapEntry::key}, #t116.{core::MapEntry::value});
       }
     }
-    #t114.{core::Map::[]=}(let final self::test2::N1 #t117 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final self::test2::N1 #t118 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
+    #t114.{core::Map::[]=}{Invariant}(let final self::test2::N1 #t117 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."), let final self::test2::N1 #t118 = n1 in throw new _in::ReachabilityError::•("`null` encountered as the result from expression with type `Never`."));
   } =>#t114;
 }
 static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/issue43256.dart.strong.expect b/pkg/front_end/testcases/nnbd/issue43256.dart.strong.expect
index c66b4918..d4b69b6 100644
--- a/pkg/front_end/testcases/nnbd/issue43256.dart.strong.expect
+++ b/pkg/front_end/testcases/nnbd/issue43256.dart.strong.expect
@@ -58,91 +58,91 @@
 static field core::Map<dynamic, dynamic> map1 = block {
   final core::Map<dynamic, dynamic> #t1 = <dynamic, dynamic>{};
   if(self::i.{core::num::>}(0))
-    #t1.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:16:17: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+    #t1.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:16:17: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
   if (i > 0) ...nullableMap, // error
                 ^", null);
   if(self::i.{core::num::>}(0))
     for (final core::MapEntry<dynamic, dynamic> #t2 in (self::dynamicMap as{TypeError,ForDynamic,ForNonNullableByDefault} core::Map<dynamic, dynamic>).{core::Map::entries})
-      #t1.{core::Map::[]=}(#t2.{core::MapEntry::key}, #t2.{core::MapEntry::value});
+      #t1.{core::Map::[]=}{Invariant}(#t2.{core::MapEntry::key}, #t2.{core::MapEntry::value});
   if(self::i.{core::num::>}(0))
     for (final core::MapEntry<dynamic, dynamic> #t3 in self::nullableMap!.{core::Map::entries})
-      #t1.{core::Map::[]=}(#t3.{core::MapEntry::key}, #t3.{core::MapEntry::value});
+      #t1.{core::Map::[]=}{Invariant}(#t3.{core::MapEntry::key}, #t3.{core::MapEntry::value});
 } =>#t1;
 static field core::Set<dynamic> set1 = block {
   final core::Set<dynamic> #t4 = col::LinkedHashSet::•<dynamic>();
-  #t4.{core::Set::add}(0);
+  #t4.{core::Set::add}{Invariant}(0);
   if(self::i.{core::num::>}(0))
-    #t4.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:23:17: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+    #t4.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:23:17: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
   if (i > 0) ...nullableList, // error
                 ^");
   if(self::i.{core::num::>}(0))
     for (final dynamic #t5 in self::dynamicList as{TypeError,ForDynamic,ForNonNullableByDefault} core::Iterable<dynamic>)
-      #t4.{core::Set::add}(#t5);
+      #t4.{core::Set::add}{Invariant}(#t5);
   if(self::i.{core::num::>}(0))
     for (final dynamic #t6 in self::nullableList!)
-      #t4.{core::Set::add}(#t6);
+      #t4.{core::Set::add}{Invariant}(#t6);
 } =>#t4;
 static field core::List<dynamic> list1 = block {
   final core::List<dynamic> #t7 = <dynamic>[];
   if(self::i.{core::num::>}(0))
-    #t7.{core::List::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:29:17: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+    #t7.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:29:17: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
   if (i > 0) ...nullableList, // error
                 ^");
   if(self::i.{core::num::>}(0))
     for (final dynamic #t8 in self::dynamicList as{TypeError,ForDynamic,ForNonNullableByDefault} core::Iterable<dynamic>)
-      #t7.{core::List::add}(#t8);
+      #t7.{core::List::add}{Invariant}(#t8);
   if(self::i.{core::num::>}(0))
     for (final dynamic #t9 in self::nullableList!)
-      #t7.{core::List::add}(#t9);
+      #t7.{core::List::add}{Invariant}(#t9);
 } =>#t7;
 static method testMap<X extends dynamic = dynamic, Y extends core::Map<core::int, core::String>? = core::Map<core::int, core::String>?, Z extends core::Map<core::int, core::String> = core::Map<core::int, core::String>>(self::testMap::X% x, self::testMap::Y% y, self::testMap::Z z) → dynamic {
   core::Map<dynamic, dynamic> map2 = block {
     final core::Map<dynamic, dynamic> #t10 = <dynamic, dynamic>{};
     if(self::i.{core::num::>}(0))
-      #t10.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:37:19: Error: Unexpected type 'X' of a map spread entry.  Expected 'dynamic' or a Map.
+      #t10.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:37:19: Error: Unexpected type 'X' of a map spread entry.  Expected 'dynamic' or a Map.
     if (i > 0) ...x, // error
                   ^", null);
     if(self::i.{core::num::>}(0))
-      #t10.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:38:19: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t10.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:38:19: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     if (i > 0) ...y, // error
                   ^", null);
     if(self::i.{core::num::>}(0))
       for (final core::MapEntry<dynamic, dynamic> #t11 in z.{core::Map::entries})
-        #t10.{core::Map::[]=}(#t11.{core::MapEntry::key}, #t11.{core::MapEntry::value});
+        #t10.{core::Map::[]=}{Invariant}(#t11.{core::MapEntry::key}, #t11.{core::MapEntry::value});
     if(self::i.{core::num::>}(0))
       for (final core::MapEntry<dynamic, dynamic> #t12 in y!.{core::Map::entries})
-        #t10.{core::Map::[]=}(#t12.{core::MapEntry::key}, #t12.{core::MapEntry::value});
+        #t10.{core::Map::[]=}{Invariant}(#t12.{core::MapEntry::key}, #t12.{core::MapEntry::value});
   } =>#t10;
 }
 static method testIterables<X extends dynamic = dynamic, Y extends core::List<core::int>? = core::List<core::int>?, Z extends core::List<core::int> = core::List<core::int>>(self::testIterables::X% x, self::testIterables::Y% y, self::testIterables::Z z) → dynamic {
   core::Set<dynamic> set2 = block {
     final core::Set<dynamic> #t13 = col::LinkedHashSet::•<dynamic>();
-    #t13.{core::Set::add}(0);
+    #t13.{core::Set::add}{Invariant}(0);
     if(self::i.{core::num::>}(0))
-      #t13.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:48:19: Error: Unexpected type 'X' of a spread.  Expected 'dynamic' or an Iterable.
+      #t13.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:48:19: Error: Unexpected type 'X' of a spread.  Expected 'dynamic' or an Iterable.
     if (i > 0) ...x, // error
                   ^");
     if(self::i.{core::num::>}(0))
-      #t13.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:49:19: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t13.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:49:19: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     if (i > 0) ...y, // error
                   ^");
     if(self::i.{core::num::>}(0))
       for (final dynamic #t14 in z)
-        #t13.{core::Set::add}(#t14);
+        #t13.{core::Set::add}{Invariant}(#t14);
   } =>#t13;
   core::List<dynamic> list2 = block {
     final core::List<dynamic> #t15 = <dynamic>[];
     if(self::i.{core::num::>}(0))
-      #t15.{core::List::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:53:19: Error: Unexpected type 'X' of a spread.  Expected 'dynamic' or an Iterable.
+      #t15.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:53:19: Error: Unexpected type 'X' of a spread.  Expected 'dynamic' or an Iterable.
     if (i > 0) ...x, // error
                   ^");
     if(self::i.{core::num::>}(0))
-      #t15.{core::List::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:54:19: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t15.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:54:19: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     if (i > 0) ...y, // error
                   ^");
     if(self::i.{core::num::>}(0))
       for (final dynamic #t16 in z)
-        #t15.{core::List::add}(#t16);
+        #t15.{core::List::add}{Invariant}(#t16);
   } =>#t15;
 }
 static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/issue43256.dart.strong.transformed.expect b/pkg/front_end/testcases/nnbd/issue43256.dart.strong.transformed.expect
index 32a8e8e..7babee3 100644
--- a/pkg/front_end/testcases/nnbd/issue43256.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/nnbd/issue43256.dart.strong.transformed.expect
@@ -58,64 +58,64 @@
 static field core::Map<dynamic, dynamic> map1 = block {
   final core::Map<dynamic, dynamic> #t1 = <dynamic, dynamic>{};
   if(self::i.{core::num::>}(0))
-    #t1.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:16:17: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+    #t1.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:16:17: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
   if (i > 0) ...nullableMap, // error
                 ^", null);
   if(self::i.{core::num::>}(0)) {
     core::Iterator<core::MapEntry<dynamic, dynamic>> :sync-for-iterator = (self::dynamicMap as{TypeError,ForDynamic,ForNonNullableByDefault} core::Map<dynamic, dynamic>).{core::Map::entries}.{core::Iterable::iterator};
     for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
       final core::MapEntry<dynamic, dynamic> #t2 = :sync-for-iterator.{core::Iterator::current};
-      #t1.{core::Map::[]=}(#t2.{core::MapEntry::key}, #t2.{core::MapEntry::value});
+      #t1.{core::Map::[]=}{Invariant}(#t2.{core::MapEntry::key}, #t2.{core::MapEntry::value});
     }
   }
   if(self::i.{core::num::>}(0)) {
     core::Iterator<core::MapEntry<core::int, core::String>> :sync-for-iterator = self::nullableMap!.{core::Map::entries}.{core::Iterable::iterator};
     for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
       final core::MapEntry<dynamic, dynamic> #t3 = :sync-for-iterator.{core::Iterator::current};
-      #t1.{core::Map::[]=}(#t3.{core::MapEntry::key}, #t3.{core::MapEntry::value});
+      #t1.{core::Map::[]=}{Invariant}(#t3.{core::MapEntry::key}, #t3.{core::MapEntry::value});
     }
   }
 } =>#t1;
 static field core::Set<dynamic> set1 = block {
   final core::Set<dynamic> #t4 = new col::_CompactLinkedHashSet::•<dynamic>();
-  #t4.{core::Set::add}(0);
+  #t4.{core::Set::add}{Invariant}(0);
   if(self::i.{core::num::>}(0))
-    #t4.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:23:17: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+    #t4.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:23:17: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
   if (i > 0) ...nullableList, // error
                 ^");
   if(self::i.{core::num::>}(0)) {
     core::Iterator<dynamic> :sync-for-iterator = (self::dynamicList as{TypeError,ForDynamic,ForNonNullableByDefault} core::Iterable<dynamic>).{core::Iterable::iterator};
     for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
       final dynamic #t5 = :sync-for-iterator.{core::Iterator::current};
-      #t4.{core::Set::add}(#t5);
+      #t4.{core::Set::add}{Invariant}(#t5);
     }
   }
   if(self::i.{core::num::>}(0)) {
     core::Iterator<core::int> :sync-for-iterator = self::nullableList!.{core::Iterable::iterator};
     for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
       final dynamic #t6 = :sync-for-iterator.{core::Iterator::current};
-      #t4.{core::Set::add}(#t6);
+      #t4.{core::Set::add}{Invariant}(#t6);
     }
   }
 } =>#t4;
 static field core::List<dynamic> list1 = block {
   final core::List<dynamic> #t7 = <dynamic>[];
   if(self::i.{core::num::>}(0))
-    #t7.{core::List::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:29:17: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+    #t7.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:29:17: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
   if (i > 0) ...nullableList, // error
                 ^");
   if(self::i.{core::num::>}(0)) {
     core::Iterator<dynamic> :sync-for-iterator = (self::dynamicList as{TypeError,ForDynamic,ForNonNullableByDefault} core::Iterable<dynamic>).{core::Iterable::iterator};
     for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
       final dynamic #t8 = :sync-for-iterator.{core::Iterator::current};
-      #t7.{core::List::add}(#t8);
+      #t7.{core::List::add}{Invariant}(#t8);
     }
   }
   if(self::i.{core::num::>}(0)) {
     core::Iterator<core::int> :sync-for-iterator = self::nullableList!.{core::Iterable::iterator};
     for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
       final dynamic #t9 = :sync-for-iterator.{core::Iterator::current};
-      #t7.{core::List::add}(#t9);
+      #t7.{core::List::add}{Invariant}(#t9);
     }
   }
 } =>#t7;
@@ -123,25 +123,25 @@
   core::Map<dynamic, dynamic> map2 = block {
     final core::Map<dynamic, dynamic> #t10 = <dynamic, dynamic>{};
     if(self::i.{core::num::>}(0))
-      #t10.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:37:19: Error: Unexpected type 'X' of a map spread entry.  Expected 'dynamic' or a Map.
+      #t10.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:37:19: Error: Unexpected type 'X' of a map spread entry.  Expected 'dynamic' or a Map.
     if (i > 0) ...x, // error
                   ^", null);
     if(self::i.{core::num::>}(0))
-      #t10.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:38:19: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t10.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:38:19: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     if (i > 0) ...y, // error
                   ^", null);
     if(self::i.{core::num::>}(0)) {
       core::Iterator<core::MapEntry<core::int, core::String>> :sync-for-iterator = z.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<dynamic, dynamic> #t11 = :sync-for-iterator.{core::Iterator::current};
-        #t10.{core::Map::[]=}(#t11.{core::MapEntry::key}, #t11.{core::MapEntry::value});
+        #t10.{core::Map::[]=}{Invariant}(#t11.{core::MapEntry::key}, #t11.{core::MapEntry::value});
       }
     }
     if(self::i.{core::num::>}(0)) {
       core::Iterator<core::MapEntry<core::int, core::String>> :sync-for-iterator = y!.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<dynamic, dynamic> #t12 = :sync-for-iterator.{core::Iterator::current};
-        #t10.{core::Map::[]=}(#t12.{core::MapEntry::key}, #t12.{core::MapEntry::value});
+        #t10.{core::Map::[]=}{Invariant}(#t12.{core::MapEntry::key}, #t12.{core::MapEntry::value});
       }
     }
   } =>#t10;
@@ -149,38 +149,38 @@
 static method testIterables<X extends dynamic = dynamic, Y extends core::List<core::int>? = core::List<core::int>?, Z extends core::List<core::int> = core::List<core::int>>(self::testIterables::X% x, self::testIterables::Y% y, self::testIterables::Z z) → dynamic {
   core::Set<dynamic> set2 = block {
     final core::Set<dynamic> #t13 = new col::_CompactLinkedHashSet::•<dynamic>();
-    #t13.{core::Set::add}(0);
+    #t13.{core::Set::add}{Invariant}(0);
     if(self::i.{core::num::>}(0))
-      #t13.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:48:19: Error: Unexpected type 'X' of a spread.  Expected 'dynamic' or an Iterable.
+      #t13.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:48:19: Error: Unexpected type 'X' of a spread.  Expected 'dynamic' or an Iterable.
     if (i > 0) ...x, // error
                   ^");
     if(self::i.{core::num::>}(0))
-      #t13.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:49:19: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t13.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:49:19: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     if (i > 0) ...y, // error
                   ^");
     if(self::i.{core::num::>}(0)) {
       core::Iterator<core::int> :sync-for-iterator = z.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final dynamic #t14 = :sync-for-iterator.{core::Iterator::current};
-        #t13.{core::Set::add}(#t14);
+        #t13.{core::Set::add}{Invariant}(#t14);
       }
     }
   } =>#t13;
   core::List<dynamic> list2 = block {
     final core::List<dynamic> #t15 = <dynamic>[];
     if(self::i.{core::num::>}(0))
-      #t15.{core::List::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:53:19: Error: Unexpected type 'X' of a spread.  Expected 'dynamic' or an Iterable.
+      #t15.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:53:19: Error: Unexpected type 'X' of a spread.  Expected 'dynamic' or an Iterable.
     if (i > 0) ...x, // error
                   ^");
     if(self::i.{core::num::>}(0))
-      #t15.{core::List::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:54:19: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t15.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:54:19: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     if (i > 0) ...y, // error
                   ^");
     if(self::i.{core::num::>}(0)) {
       core::Iterator<core::int> :sync-for-iterator = z.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final dynamic #t16 = :sync-for-iterator.{core::Iterator::current};
-        #t15.{core::List::add}(#t16);
+        #t15.{core::List::add}{Invariant}(#t16);
       }
     }
   } =>#t15;
diff --git a/pkg/front_end/testcases/nnbd/issue43256.dart.weak.expect b/pkg/front_end/testcases/nnbd/issue43256.dart.weak.expect
index c66b4918..d4b69b6 100644
--- a/pkg/front_end/testcases/nnbd/issue43256.dart.weak.expect
+++ b/pkg/front_end/testcases/nnbd/issue43256.dart.weak.expect
@@ -58,91 +58,91 @@
 static field core::Map<dynamic, dynamic> map1 = block {
   final core::Map<dynamic, dynamic> #t1 = <dynamic, dynamic>{};
   if(self::i.{core::num::>}(0))
-    #t1.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:16:17: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+    #t1.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:16:17: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
   if (i > 0) ...nullableMap, // error
                 ^", null);
   if(self::i.{core::num::>}(0))
     for (final core::MapEntry<dynamic, dynamic> #t2 in (self::dynamicMap as{TypeError,ForDynamic,ForNonNullableByDefault} core::Map<dynamic, dynamic>).{core::Map::entries})
-      #t1.{core::Map::[]=}(#t2.{core::MapEntry::key}, #t2.{core::MapEntry::value});
+      #t1.{core::Map::[]=}{Invariant}(#t2.{core::MapEntry::key}, #t2.{core::MapEntry::value});
   if(self::i.{core::num::>}(0))
     for (final core::MapEntry<dynamic, dynamic> #t3 in self::nullableMap!.{core::Map::entries})
-      #t1.{core::Map::[]=}(#t3.{core::MapEntry::key}, #t3.{core::MapEntry::value});
+      #t1.{core::Map::[]=}{Invariant}(#t3.{core::MapEntry::key}, #t3.{core::MapEntry::value});
 } =>#t1;
 static field core::Set<dynamic> set1 = block {
   final core::Set<dynamic> #t4 = col::LinkedHashSet::•<dynamic>();
-  #t4.{core::Set::add}(0);
+  #t4.{core::Set::add}{Invariant}(0);
   if(self::i.{core::num::>}(0))
-    #t4.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:23:17: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+    #t4.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:23:17: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
   if (i > 0) ...nullableList, // error
                 ^");
   if(self::i.{core::num::>}(0))
     for (final dynamic #t5 in self::dynamicList as{TypeError,ForDynamic,ForNonNullableByDefault} core::Iterable<dynamic>)
-      #t4.{core::Set::add}(#t5);
+      #t4.{core::Set::add}{Invariant}(#t5);
   if(self::i.{core::num::>}(0))
     for (final dynamic #t6 in self::nullableList!)
-      #t4.{core::Set::add}(#t6);
+      #t4.{core::Set::add}{Invariant}(#t6);
 } =>#t4;
 static field core::List<dynamic> list1 = block {
   final core::List<dynamic> #t7 = <dynamic>[];
   if(self::i.{core::num::>}(0))
-    #t7.{core::List::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:29:17: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+    #t7.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:29:17: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
   if (i > 0) ...nullableList, // error
                 ^");
   if(self::i.{core::num::>}(0))
     for (final dynamic #t8 in self::dynamicList as{TypeError,ForDynamic,ForNonNullableByDefault} core::Iterable<dynamic>)
-      #t7.{core::List::add}(#t8);
+      #t7.{core::List::add}{Invariant}(#t8);
   if(self::i.{core::num::>}(0))
     for (final dynamic #t9 in self::nullableList!)
-      #t7.{core::List::add}(#t9);
+      #t7.{core::List::add}{Invariant}(#t9);
 } =>#t7;
 static method testMap<X extends dynamic = dynamic, Y extends core::Map<core::int, core::String>? = core::Map<core::int, core::String>?, Z extends core::Map<core::int, core::String> = core::Map<core::int, core::String>>(self::testMap::X% x, self::testMap::Y% y, self::testMap::Z z) → dynamic {
   core::Map<dynamic, dynamic> map2 = block {
     final core::Map<dynamic, dynamic> #t10 = <dynamic, dynamic>{};
     if(self::i.{core::num::>}(0))
-      #t10.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:37:19: Error: Unexpected type 'X' of a map spread entry.  Expected 'dynamic' or a Map.
+      #t10.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:37:19: Error: Unexpected type 'X' of a map spread entry.  Expected 'dynamic' or a Map.
     if (i > 0) ...x, // error
                   ^", null);
     if(self::i.{core::num::>}(0))
-      #t10.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:38:19: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t10.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:38:19: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     if (i > 0) ...y, // error
                   ^", null);
     if(self::i.{core::num::>}(0))
       for (final core::MapEntry<dynamic, dynamic> #t11 in z.{core::Map::entries})
-        #t10.{core::Map::[]=}(#t11.{core::MapEntry::key}, #t11.{core::MapEntry::value});
+        #t10.{core::Map::[]=}{Invariant}(#t11.{core::MapEntry::key}, #t11.{core::MapEntry::value});
     if(self::i.{core::num::>}(0))
       for (final core::MapEntry<dynamic, dynamic> #t12 in y!.{core::Map::entries})
-        #t10.{core::Map::[]=}(#t12.{core::MapEntry::key}, #t12.{core::MapEntry::value});
+        #t10.{core::Map::[]=}{Invariant}(#t12.{core::MapEntry::key}, #t12.{core::MapEntry::value});
   } =>#t10;
 }
 static method testIterables<X extends dynamic = dynamic, Y extends core::List<core::int>? = core::List<core::int>?, Z extends core::List<core::int> = core::List<core::int>>(self::testIterables::X% x, self::testIterables::Y% y, self::testIterables::Z z) → dynamic {
   core::Set<dynamic> set2 = block {
     final core::Set<dynamic> #t13 = col::LinkedHashSet::•<dynamic>();
-    #t13.{core::Set::add}(0);
+    #t13.{core::Set::add}{Invariant}(0);
     if(self::i.{core::num::>}(0))
-      #t13.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:48:19: Error: Unexpected type 'X' of a spread.  Expected 'dynamic' or an Iterable.
+      #t13.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:48:19: Error: Unexpected type 'X' of a spread.  Expected 'dynamic' or an Iterable.
     if (i > 0) ...x, // error
                   ^");
     if(self::i.{core::num::>}(0))
-      #t13.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:49:19: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t13.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:49:19: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     if (i > 0) ...y, // error
                   ^");
     if(self::i.{core::num::>}(0))
       for (final dynamic #t14 in z)
-        #t13.{core::Set::add}(#t14);
+        #t13.{core::Set::add}{Invariant}(#t14);
   } =>#t13;
   core::List<dynamic> list2 = block {
     final core::List<dynamic> #t15 = <dynamic>[];
     if(self::i.{core::num::>}(0))
-      #t15.{core::List::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:53:19: Error: Unexpected type 'X' of a spread.  Expected 'dynamic' or an Iterable.
+      #t15.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:53:19: Error: Unexpected type 'X' of a spread.  Expected 'dynamic' or an Iterable.
     if (i > 0) ...x, // error
                   ^");
     if(self::i.{core::num::>}(0))
-      #t15.{core::List::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:54:19: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t15.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:54:19: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     if (i > 0) ...y, // error
                   ^");
     if(self::i.{core::num::>}(0))
       for (final dynamic #t16 in z)
-        #t15.{core::List::add}(#t16);
+        #t15.{core::List::add}{Invariant}(#t16);
   } =>#t15;
 }
 static method main() → dynamic {}
diff --git a/pkg/front_end/testcases/nnbd/issue43256.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd/issue43256.dart.weak.transformed.expect
index 32a8e8e..7babee3 100644
--- a/pkg/front_end/testcases/nnbd/issue43256.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/nnbd/issue43256.dart.weak.transformed.expect
@@ -58,64 +58,64 @@
 static field core::Map<dynamic, dynamic> map1 = block {
   final core::Map<dynamic, dynamic> #t1 = <dynamic, dynamic>{};
   if(self::i.{core::num::>}(0))
-    #t1.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:16:17: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+    #t1.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:16:17: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
   if (i > 0) ...nullableMap, // error
                 ^", null);
   if(self::i.{core::num::>}(0)) {
     core::Iterator<core::MapEntry<dynamic, dynamic>> :sync-for-iterator = (self::dynamicMap as{TypeError,ForDynamic,ForNonNullableByDefault} core::Map<dynamic, dynamic>).{core::Map::entries}.{core::Iterable::iterator};
     for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
       final core::MapEntry<dynamic, dynamic> #t2 = :sync-for-iterator.{core::Iterator::current};
-      #t1.{core::Map::[]=}(#t2.{core::MapEntry::key}, #t2.{core::MapEntry::value});
+      #t1.{core::Map::[]=}{Invariant}(#t2.{core::MapEntry::key}, #t2.{core::MapEntry::value});
     }
   }
   if(self::i.{core::num::>}(0)) {
     core::Iterator<core::MapEntry<core::int, core::String>> :sync-for-iterator = self::nullableMap!.{core::Map::entries}.{core::Iterable::iterator};
     for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
       final core::MapEntry<dynamic, dynamic> #t3 = :sync-for-iterator.{core::Iterator::current};
-      #t1.{core::Map::[]=}(#t3.{core::MapEntry::key}, #t3.{core::MapEntry::value});
+      #t1.{core::Map::[]=}{Invariant}(#t3.{core::MapEntry::key}, #t3.{core::MapEntry::value});
     }
   }
 } =>#t1;
 static field core::Set<dynamic> set1 = block {
   final core::Set<dynamic> #t4 = new col::_CompactLinkedHashSet::•<dynamic>();
-  #t4.{core::Set::add}(0);
+  #t4.{core::Set::add}{Invariant}(0);
   if(self::i.{core::num::>}(0))
-    #t4.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:23:17: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+    #t4.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:23:17: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
   if (i > 0) ...nullableList, // error
                 ^");
   if(self::i.{core::num::>}(0)) {
     core::Iterator<dynamic> :sync-for-iterator = (self::dynamicList as{TypeError,ForDynamic,ForNonNullableByDefault} core::Iterable<dynamic>).{core::Iterable::iterator};
     for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
       final dynamic #t5 = :sync-for-iterator.{core::Iterator::current};
-      #t4.{core::Set::add}(#t5);
+      #t4.{core::Set::add}{Invariant}(#t5);
     }
   }
   if(self::i.{core::num::>}(0)) {
     core::Iterator<core::int> :sync-for-iterator = self::nullableList!.{core::Iterable::iterator};
     for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
       final dynamic #t6 = :sync-for-iterator.{core::Iterator::current};
-      #t4.{core::Set::add}(#t6);
+      #t4.{core::Set::add}{Invariant}(#t6);
     }
   }
 } =>#t4;
 static field core::List<dynamic> list1 = block {
   final core::List<dynamic> #t7 = <dynamic>[];
   if(self::i.{core::num::>}(0))
-    #t7.{core::List::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:29:17: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+    #t7.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:29:17: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
   if (i > 0) ...nullableList, // error
                 ^");
   if(self::i.{core::num::>}(0)) {
     core::Iterator<dynamic> :sync-for-iterator = (self::dynamicList as{TypeError,ForDynamic,ForNonNullableByDefault} core::Iterable<dynamic>).{core::Iterable::iterator};
     for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
       final dynamic #t8 = :sync-for-iterator.{core::Iterator::current};
-      #t7.{core::List::add}(#t8);
+      #t7.{core::List::add}{Invariant}(#t8);
     }
   }
   if(self::i.{core::num::>}(0)) {
     core::Iterator<core::int> :sync-for-iterator = self::nullableList!.{core::Iterable::iterator};
     for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
       final dynamic #t9 = :sync-for-iterator.{core::Iterator::current};
-      #t7.{core::List::add}(#t9);
+      #t7.{core::List::add}{Invariant}(#t9);
     }
   }
 } =>#t7;
@@ -123,25 +123,25 @@
   core::Map<dynamic, dynamic> map2 = block {
     final core::Map<dynamic, dynamic> #t10 = <dynamic, dynamic>{};
     if(self::i.{core::num::>}(0))
-      #t10.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:37:19: Error: Unexpected type 'X' of a map spread entry.  Expected 'dynamic' or a Map.
+      #t10.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:37:19: Error: Unexpected type 'X' of a map spread entry.  Expected 'dynamic' or a Map.
     if (i > 0) ...x, // error
                   ^", null);
     if(self::i.{core::num::>}(0))
-      #t10.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:38:19: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t10.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:38:19: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     if (i > 0) ...y, // error
                   ^", null);
     if(self::i.{core::num::>}(0)) {
       core::Iterator<core::MapEntry<core::int, core::String>> :sync-for-iterator = z.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<dynamic, dynamic> #t11 = :sync-for-iterator.{core::Iterator::current};
-        #t10.{core::Map::[]=}(#t11.{core::MapEntry::key}, #t11.{core::MapEntry::value});
+        #t10.{core::Map::[]=}{Invariant}(#t11.{core::MapEntry::key}, #t11.{core::MapEntry::value});
       }
     }
     if(self::i.{core::num::>}(0)) {
       core::Iterator<core::MapEntry<core::int, core::String>> :sync-for-iterator = y!.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<dynamic, dynamic> #t12 = :sync-for-iterator.{core::Iterator::current};
-        #t10.{core::Map::[]=}(#t12.{core::MapEntry::key}, #t12.{core::MapEntry::value});
+        #t10.{core::Map::[]=}{Invariant}(#t12.{core::MapEntry::key}, #t12.{core::MapEntry::value});
       }
     }
   } =>#t10;
@@ -149,38 +149,38 @@
 static method testIterables<X extends dynamic = dynamic, Y extends core::List<core::int>? = core::List<core::int>?, Z extends core::List<core::int> = core::List<core::int>>(self::testIterables::X% x, self::testIterables::Y% y, self::testIterables::Z z) → dynamic {
   core::Set<dynamic> set2 = block {
     final core::Set<dynamic> #t13 = new col::_CompactLinkedHashSet::•<dynamic>();
-    #t13.{core::Set::add}(0);
+    #t13.{core::Set::add}{Invariant}(0);
     if(self::i.{core::num::>}(0))
-      #t13.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:48:19: Error: Unexpected type 'X' of a spread.  Expected 'dynamic' or an Iterable.
+      #t13.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:48:19: Error: Unexpected type 'X' of a spread.  Expected 'dynamic' or an Iterable.
     if (i > 0) ...x, // error
                   ^");
     if(self::i.{core::num::>}(0))
-      #t13.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:49:19: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t13.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:49:19: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     if (i > 0) ...y, // error
                   ^");
     if(self::i.{core::num::>}(0)) {
       core::Iterator<core::int> :sync-for-iterator = z.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final dynamic #t14 = :sync-for-iterator.{core::Iterator::current};
-        #t13.{core::Set::add}(#t14);
+        #t13.{core::Set::add}{Invariant}(#t14);
       }
     }
   } =>#t13;
   core::List<dynamic> list2 = block {
     final core::List<dynamic> #t15 = <dynamic>[];
     if(self::i.{core::num::>}(0))
-      #t15.{core::List::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:53:19: Error: Unexpected type 'X' of a spread.  Expected 'dynamic' or an Iterable.
+      #t15.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:53:19: Error: Unexpected type 'X' of a spread.  Expected 'dynamic' or an Iterable.
     if (i > 0) ...x, // error
                   ^");
     if(self::i.{core::num::>}(0))
-      #t15.{core::List::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:54:19: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t15.{core::List::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43256.dart:54:19: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     if (i > 0) ...y, // error
                   ^");
     if(self::i.{core::num::>}(0)) {
       core::Iterator<core::int> :sync-for-iterator = z.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final dynamic #t16 = :sync-for-iterator.{core::Iterator::current};
-        #t15.{core::List::add}(#t16);
+        #t15.{core::List::add}{Invariant}(#t16);
       }
     }
   } =>#t15;
diff --git a/pkg/front_end/testcases/nnbd/issue43455.dart.strong.expect b/pkg/front_end/testcases/nnbd/issue43455.dart.strong.expect
index 4e5a51e..e6ba91c 100644
--- a/pkg/front_end/testcases/nnbd/issue43455.dart.strong.expect
+++ b/pkg/front_end/testcases/nnbd/issue43455.dart.strong.expect
@@ -10,23 +10,23 @@
   method test(generic-covariant-impl self::C::X% x, generic-covariant-impl self::C::Y? y) → dynamic {
     core::Set<core::Object?> v = block {
       final core::Set<core::Object?> #t1 = col::LinkedHashSet::•<core::Object?>();
-      #t1.{core::Set::add}(x);
-      #t1.{core::Set::add}(42);
+      #t1.{core::Set::add}{Invariant}(x);
+      #t1.{core::Set::add}{Invariant}(42);
     } =>#t1;
     core::Set<core::Object?> w = block {
       final core::Set<core::Object?> #t2 = col::LinkedHashSet::•<core::Object?>();
-      #t2.{core::Set::add}(42);
-      #t2.{core::Set::add}(x);
+      #t2.{core::Set::add}{Invariant}(42);
+      #t2.{core::Set::add}{Invariant}(x);
     } =>#t2;
     core::Set<core::Object?> p = block {
       final core::Set<core::Object?> #t3 = col::LinkedHashSet::•<core::Object?>();
-      #t3.{core::Set::add}(y);
-      #t3.{core::Set::add}(42);
+      #t3.{core::Set::add}{Invariant}(y);
+      #t3.{core::Set::add}{Invariant}(42);
     } =>#t3;
     core::Set<core::Object?> q = block {
       final core::Set<core::Object?> #t4 = col::LinkedHashSet::•<core::Object?>();
-      #t4.{core::Set::add}(42);
-      #t4.{core::Set::add}(y);
+      #t4.{core::Set::add}{Invariant}(42);
+      #t4.{core::Set::add}{Invariant}(y);
     } =>#t4;
     self::assertRightSubtype(v);
     self::assertLeftSubtype<core::Set<core::Object?>>(v);
@@ -39,13 +39,13 @@
     if(x is{ForNonNullableByDefault} core::Object?) {
       core::Set<core::Object?> v = block {
         final core::Set<core::Object?> #t5 = col::LinkedHashSet::•<core::Object?>();
-        #t5.{core::Set::add}(x{self::C::X% & core::Object? /* '%' & '?' = '%' */});
-        #t5.{core::Set::add}(42);
+        #t5.{core::Set::add}{Invariant}(x{self::C::X% & core::Object? /* '%' & '?' = '%' */});
+        #t5.{core::Set::add}{Invariant}(42);
       } =>#t5;
       core::Set<core::Object?> w = block {
         final core::Set<core::Object?> #t6 = col::LinkedHashSet::•<core::Object?>();
-        #t6.{core::Set::add}(42);
-        #t6.{core::Set::add}(x{self::C::X% & core::Object? /* '%' & '?' = '%' */});
+        #t6.{core::Set::add}{Invariant}(42);
+        #t6.{core::Set::add}{Invariant}(x{self::C::X% & core::Object? /* '%' & '?' = '%' */});
       } =>#t6;
       self::assertRightSubtype(v);
       self::assertLeftSubtype<core::Set<core::Object?>>(v);
diff --git a/pkg/front_end/testcases/nnbd/issue43455.dart.strong.transformed.expect b/pkg/front_end/testcases/nnbd/issue43455.dart.strong.transformed.expect
index 57588b2..47bd5a2 100644
--- a/pkg/front_end/testcases/nnbd/issue43455.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/nnbd/issue43455.dart.strong.transformed.expect
@@ -10,23 +10,23 @@
   method test(generic-covariant-impl self::C::X% x, generic-covariant-impl self::C::Y? y) → dynamic {
     core::Set<core::Object?> v = block {
       final core::Set<core::Object?> #t1 = new col::_CompactLinkedHashSet::•<core::Object?>();
-      #t1.{core::Set::add}(x);
-      #t1.{core::Set::add}(42);
+      #t1.{core::Set::add}{Invariant}(x);
+      #t1.{core::Set::add}{Invariant}(42);
     } =>#t1;
     core::Set<core::Object?> w = block {
       final core::Set<core::Object?> #t2 = new col::_CompactLinkedHashSet::•<core::Object?>();
-      #t2.{core::Set::add}(42);
-      #t2.{core::Set::add}(x);
+      #t2.{core::Set::add}{Invariant}(42);
+      #t2.{core::Set::add}{Invariant}(x);
     } =>#t2;
     core::Set<core::Object?> p = block {
       final core::Set<core::Object?> #t3 = new col::_CompactLinkedHashSet::•<core::Object?>();
-      #t3.{core::Set::add}(y);
-      #t3.{core::Set::add}(42);
+      #t3.{core::Set::add}{Invariant}(y);
+      #t3.{core::Set::add}{Invariant}(42);
     } =>#t3;
     core::Set<core::Object?> q = block {
       final core::Set<core::Object?> #t4 = new col::_CompactLinkedHashSet::•<core::Object?>();
-      #t4.{core::Set::add}(42);
-      #t4.{core::Set::add}(y);
+      #t4.{core::Set::add}{Invariant}(42);
+      #t4.{core::Set::add}{Invariant}(y);
     } =>#t4;
     self::assertRightSubtype(v);
     self::assertLeftSubtype<core::Set<core::Object?>>(v);
@@ -39,13 +39,13 @@
     if(x is{ForNonNullableByDefault} core::Object?) {
       core::Set<core::Object?> v = block {
         final core::Set<core::Object?> #t5 = new col::_CompactLinkedHashSet::•<core::Object?>();
-        #t5.{core::Set::add}(x{self::C::X% & core::Object? /* '%' & '?' = '%' */});
-        #t5.{core::Set::add}(42);
+        #t5.{core::Set::add}{Invariant}(x{self::C::X% & core::Object? /* '%' & '?' = '%' */});
+        #t5.{core::Set::add}{Invariant}(42);
       } =>#t5;
       core::Set<core::Object?> w = block {
         final core::Set<core::Object?> #t6 = new col::_CompactLinkedHashSet::•<core::Object?>();
-        #t6.{core::Set::add}(42);
-        #t6.{core::Set::add}(x{self::C::X% & core::Object? /* '%' & '?' = '%' */});
+        #t6.{core::Set::add}{Invariant}(42);
+        #t6.{core::Set::add}{Invariant}(x{self::C::X% & core::Object? /* '%' & '?' = '%' */});
       } =>#t6;
       self::assertRightSubtype(v);
       self::assertLeftSubtype<core::Set<core::Object?>>(v);
diff --git a/pkg/front_end/testcases/nnbd/issue43455.dart.weak.expect b/pkg/front_end/testcases/nnbd/issue43455.dart.weak.expect
index 4e5a51e..e6ba91c 100644
--- a/pkg/front_end/testcases/nnbd/issue43455.dart.weak.expect
+++ b/pkg/front_end/testcases/nnbd/issue43455.dart.weak.expect
@@ -10,23 +10,23 @@
   method test(generic-covariant-impl self::C::X% x, generic-covariant-impl self::C::Y? y) → dynamic {
     core::Set<core::Object?> v = block {
       final core::Set<core::Object?> #t1 = col::LinkedHashSet::•<core::Object?>();
-      #t1.{core::Set::add}(x);
-      #t1.{core::Set::add}(42);
+      #t1.{core::Set::add}{Invariant}(x);
+      #t1.{core::Set::add}{Invariant}(42);
     } =>#t1;
     core::Set<core::Object?> w = block {
       final core::Set<core::Object?> #t2 = col::LinkedHashSet::•<core::Object?>();
-      #t2.{core::Set::add}(42);
-      #t2.{core::Set::add}(x);
+      #t2.{core::Set::add}{Invariant}(42);
+      #t2.{core::Set::add}{Invariant}(x);
     } =>#t2;
     core::Set<core::Object?> p = block {
       final core::Set<core::Object?> #t3 = col::LinkedHashSet::•<core::Object?>();
-      #t3.{core::Set::add}(y);
-      #t3.{core::Set::add}(42);
+      #t3.{core::Set::add}{Invariant}(y);
+      #t3.{core::Set::add}{Invariant}(42);
     } =>#t3;
     core::Set<core::Object?> q = block {
       final core::Set<core::Object?> #t4 = col::LinkedHashSet::•<core::Object?>();
-      #t4.{core::Set::add}(42);
-      #t4.{core::Set::add}(y);
+      #t4.{core::Set::add}{Invariant}(42);
+      #t4.{core::Set::add}{Invariant}(y);
     } =>#t4;
     self::assertRightSubtype(v);
     self::assertLeftSubtype<core::Set<core::Object?>>(v);
@@ -39,13 +39,13 @@
     if(x is{ForNonNullableByDefault} core::Object?) {
       core::Set<core::Object?> v = block {
         final core::Set<core::Object?> #t5 = col::LinkedHashSet::•<core::Object?>();
-        #t5.{core::Set::add}(x{self::C::X% & core::Object? /* '%' & '?' = '%' */});
-        #t5.{core::Set::add}(42);
+        #t5.{core::Set::add}{Invariant}(x{self::C::X% & core::Object? /* '%' & '?' = '%' */});
+        #t5.{core::Set::add}{Invariant}(42);
       } =>#t5;
       core::Set<core::Object?> w = block {
         final core::Set<core::Object?> #t6 = col::LinkedHashSet::•<core::Object?>();
-        #t6.{core::Set::add}(42);
-        #t6.{core::Set::add}(x{self::C::X% & core::Object? /* '%' & '?' = '%' */});
+        #t6.{core::Set::add}{Invariant}(42);
+        #t6.{core::Set::add}{Invariant}(x{self::C::X% & core::Object? /* '%' & '?' = '%' */});
       } =>#t6;
       self::assertRightSubtype(v);
       self::assertLeftSubtype<core::Set<core::Object?>>(v);
diff --git a/pkg/front_end/testcases/nnbd/issue43455.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd/issue43455.dart.weak.transformed.expect
index 57588b2..47bd5a2 100644
--- a/pkg/front_end/testcases/nnbd/issue43455.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/nnbd/issue43455.dart.weak.transformed.expect
@@ -10,23 +10,23 @@
   method test(generic-covariant-impl self::C::X% x, generic-covariant-impl self::C::Y? y) → dynamic {
     core::Set<core::Object?> v = block {
       final core::Set<core::Object?> #t1 = new col::_CompactLinkedHashSet::•<core::Object?>();
-      #t1.{core::Set::add}(x);
-      #t1.{core::Set::add}(42);
+      #t1.{core::Set::add}{Invariant}(x);
+      #t1.{core::Set::add}{Invariant}(42);
     } =>#t1;
     core::Set<core::Object?> w = block {
       final core::Set<core::Object?> #t2 = new col::_CompactLinkedHashSet::•<core::Object?>();
-      #t2.{core::Set::add}(42);
-      #t2.{core::Set::add}(x);
+      #t2.{core::Set::add}{Invariant}(42);
+      #t2.{core::Set::add}{Invariant}(x);
     } =>#t2;
     core::Set<core::Object?> p = block {
       final core::Set<core::Object?> #t3 = new col::_CompactLinkedHashSet::•<core::Object?>();
-      #t3.{core::Set::add}(y);
-      #t3.{core::Set::add}(42);
+      #t3.{core::Set::add}{Invariant}(y);
+      #t3.{core::Set::add}{Invariant}(42);
     } =>#t3;
     core::Set<core::Object?> q = block {
       final core::Set<core::Object?> #t4 = new col::_CompactLinkedHashSet::•<core::Object?>();
-      #t4.{core::Set::add}(42);
-      #t4.{core::Set::add}(y);
+      #t4.{core::Set::add}{Invariant}(42);
+      #t4.{core::Set::add}{Invariant}(y);
     } =>#t4;
     self::assertRightSubtype(v);
     self::assertLeftSubtype<core::Set<core::Object?>>(v);
@@ -39,13 +39,13 @@
     if(x is{ForNonNullableByDefault} core::Object?) {
       core::Set<core::Object?> v = block {
         final core::Set<core::Object?> #t5 = new col::_CompactLinkedHashSet::•<core::Object?>();
-        #t5.{core::Set::add}(x{self::C::X% & core::Object? /* '%' & '?' = '%' */});
-        #t5.{core::Set::add}(42);
+        #t5.{core::Set::add}{Invariant}(x{self::C::X% & core::Object? /* '%' & '?' = '%' */});
+        #t5.{core::Set::add}{Invariant}(42);
       } =>#t5;
       core::Set<core::Object?> w = block {
         final core::Set<core::Object?> #t6 = new col::_CompactLinkedHashSet::•<core::Object?>();
-        #t6.{core::Set::add}(42);
-        #t6.{core::Set::add}(x{self::C::X% & core::Object? /* '%' & '?' = '%' */});
+        #t6.{core::Set::add}{Invariant}(42);
+        #t6.{core::Set::add}{Invariant}(x{self::C::X% & core::Object? /* '%' & '?' = '%' */});
       } =>#t6;
       self::assertRightSubtype(v);
       self::assertLeftSubtype<core::Set<core::Object?>>(v);
diff --git a/pkg/front_end/testcases/nnbd/issue43495.dart.strong.expect b/pkg/front_end/testcases/nnbd/issue43495.dart.strong.expect
index beb8959..0934075 100644
--- a/pkg/front_end/testcases/nnbd/issue43495.dart.strong.expect
+++ b/pkg/front_end/testcases/nnbd/issue43495.dart.strong.expect
@@ -175,7 +175,7 @@
     {...a}, // Error.
         ^") {
       final core::int #t3 = #t2 as{TypeError,ForNonNullableByDefault} core::int;
-      #t1.{core::Set::add}(#t3);
+      #t1.{core::Set::add}{Invariant}(#t3);
     }
   } =>#t1, block {
     final core::Set<core::int> #t4 = col::LinkedHashSet::•<core::int>();
@@ -183,7 +183,7 @@
     {...b}, // Error.
         ^") {
       final core::int #t6 = #t5 as{TypeError,ForNonNullableByDefault} core::int;
-      #t4.{core::Set::add}(#t6);
+      #t4.{core::Set::add}{Invariant}(#t6);
     }
   } =>#t4, block {
     final core::Set<core::int> #t7 = col::LinkedHashSet::•<core::int>();
@@ -191,7 +191,7 @@
     {...c}, // Error.
         ^") {
       final core::int #t9 = #t8 as{TypeError,ForNonNullableByDefault} core::int;
-      #t7.{core::Set::add}(#t9);
+      #t7.{core::Set::add}{Invariant}(#t9);
     }
   } =>#t7, <core::int, core::int>{invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:11:9: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {...d}, // Error.
@@ -200,7 +200,7 @@
     <int, int>{...a}, // Error.
                   ^": null}, block {
     final core::Set<core::int> #t10 = col::LinkedHashSet::•<core::int>();
-    #t10.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:13:14: Error: Unexpected type 'Map<int, int>?' of a spread.  Expected 'dynamic' or an Iterable.
+    #t10.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:13:14: Error: Unexpected type 'Map<int, int>?' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
     <int>{...d}, // Error.
              ^");
@@ -211,7 +211,7 @@
     {if (condition) ...a}, // Error.
                        ^") {
         final core::int #t13 = #t12 as{TypeError,ForNonNullableByDefault} core::int;
-        #t11.{core::Set::add}(#t13);
+        #t11.{core::Set::add}{Invariant}(#t13);
       }
   } =>#t11, block {
     final core::Set<core::int> #t14 = col::LinkedHashSet::•<core::int>();
@@ -220,7 +220,7 @@
     {if (condition) ...b}, // Error.
                        ^") {
         final core::int #t16 = #t15 as{TypeError,ForNonNullableByDefault} core::int;
-        #t14.{core::Set::add}(#t16);
+        #t14.{core::Set::add}{Invariant}(#t16);
       }
   } =>#t14, block {
     final core::Set<core::int> #t17 = col::LinkedHashSet::•<core::int>();
@@ -229,12 +229,12 @@
     {if (condition) ...c}, // Error.
                        ^") {
         final core::int #t19 = #t18 as{TypeError,ForNonNullableByDefault} core::int;
-        #t17.{core::Set::add}(#t19);
+        #t17.{core::Set::add}{Invariant}(#t19);
       }
   } =>#t17, block {
     final core::Map<core::int, core::int> #t20 = <core::int, core::int>{};
     if(condition)
-      #t20.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:17:24: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t20.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:17:24: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {if (condition) ...d}, // Error.
                        ^", null);
   } =>#t20, block {
@@ -244,7 +244,7 @@
     {for (dynamic e in iterable) ...a}, // Error.
                                     ^") {
         final core::int #t23 = #t22 as{TypeError,ForNonNullableByDefault} core::int;
-        #t21.{core::Set::add}(#t23);
+        #t21.{core::Set::add}{Invariant}(#t23);
       }
   } =>#t21, block {
     final core::Set<core::int> #t24 = col::LinkedHashSet::•<core::int>();
@@ -253,7 +253,7 @@
     {for (dynamic e in iterable) ...b}, // Error.
                                     ^") {
         final core::int #t26 = #t25 as{TypeError,ForNonNullableByDefault} core::int;
-        #t24.{core::Set::add}(#t26);
+        #t24.{core::Set::add}{Invariant}(#t26);
       }
   } =>#t24, block {
     final core::Set<core::int> #t27 = col::LinkedHashSet::•<core::int>();
@@ -262,12 +262,12 @@
     {for (dynamic e in iterable) ...c}, // Error.
                                     ^") {
         final core::int #t29 = #t28 as{TypeError,ForNonNullableByDefault} core::int;
-        #t27.{core::Set::add}(#t29);
+        #t27.{core::Set::add}{Invariant}(#t29);
       }
   } =>#t27, block {
     final core::Map<core::int, core::int> #t30 = <core::int, core::int>{};
     for (dynamic e in iterable)
-      #t30.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:21:37: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t30.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:21:37: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {for (dynamic e in iterable) ...d}, // Error.
                                     ^", null);
   } =>#t30, block {
@@ -277,7 +277,7 @@
     {for (int i = 0; i < 42; ++i) ...a}, // Error.
                                      ^") {
         final core::int #t33 = #t32 as{TypeError,ForNonNullableByDefault} core::int;
-        #t31.{core::Set::add}(#t33);
+        #t31.{core::Set::add}{Invariant}(#t33);
       }
   } =>#t31, block {
     final core::Set<core::int> #t34 = col::LinkedHashSet::•<core::int>();
@@ -286,7 +286,7 @@
     {for (int i = 0; i < 42; ++i) ...b}, // Error.
                                      ^") {
         final core::int #t36 = #t35 as{TypeError,ForNonNullableByDefault} core::int;
-        #t34.{core::Set::add}(#t36);
+        #t34.{core::Set::add}{Invariant}(#t36);
       }
   } =>#t34, block {
     final core::Set<core::int> #t37 = col::LinkedHashSet::•<core::int>();
@@ -295,12 +295,12 @@
     {for (int i = 0; i < 42; ++i) ...c}, // Error.
                                      ^") {
         final core::int #t39 = #t38 as{TypeError,ForNonNullableByDefault} core::int;
-        #t37.{core::Set::add}(#t39);
+        #t37.{core::Set::add}{Invariant}(#t39);
       }
   } =>#t37, block {
     final core::Map<core::int, core::int> #t40 = <core::int, core::int>{};
     for (core::int i = 0; i.{core::num::<}(42); i = i.{core::num::+}(1))
-      #t40.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:25:38: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t40.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:25:38: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {for (int i = 0; i < 42; ++i) ...d}, // Error.
                                      ^", null);
   } =>#t40, block {
@@ -309,7 +309,7 @@
     if(!#t42.{core::Object::==}(null))
       for (final dynamic #t43 in #t42{core::Iterable<dynamic>}) {
         final core::int #t44 = #t43 as{TypeError,ForNonNullableByDefault} core::int;
-        #t41.{core::Set::add}(#t44);
+        #t41.{core::Set::add}{Invariant}(#t44);
       }
   } =>#t41, block {
     final core::Set<core::int> #t45 = col::LinkedHashSet::•<core::int>();
@@ -317,7 +317,7 @@
     if(!#t46.{core::Object::==}(null))
       for (final dynamic #t47 in #t46{core::Iterable<dynamic>}) {
         final core::int #t48 = #t47 as{TypeError,ForNonNullableByDefault} core::int;
-        #t45.{core::Set::add}(#t48);
+        #t45.{core::Set::add}{Invariant}(#t48);
       }
   } =>#t45, block {
     final core::Set<core::int> #t49 = col::LinkedHashSet::•<core::int>();
@@ -325,14 +325,14 @@
     if(!#t50.{core::Object::==}(null))
       for (final dynamic #t51 in #t50{core::Iterable<dynamic>}) {
         final core::int #t52 = #t51 as{TypeError,ForNonNullableByDefault} core::int;
-        #t49.{core::Set::add}(#t52);
+        #t49.{core::Set::add}{Invariant}(#t52);
       }
   } =>#t49, block {
     final core::Map<core::int, core::int> #t53 = <core::int, core::int>{};
     final core::Map<core::int, core::int>? #t54 = d;
     if(!#t54.{core::Object::==}(null))
       for (final core::MapEntry<core::int, core::int> #t55 in #t54{core::Map<core::int, core::int>}.{core::Map::entries})
-        #t53.{core::Map::[]=}(#t55.{core::MapEntry::key}, #t55.{core::MapEntry::value});
+        #t53.{core::Map::[]=}{Invariant}(#t55.{core::MapEntry::key}, #t55.{core::MapEntry::value});
   } =>#t53, block {
     final core::Set<core::int> #t56 = col::LinkedHashSet::•<core::int>();
     if(condition) {
@@ -340,7 +340,7 @@
       if(!#t57.{core::Object::==}(null))
         for (final dynamic #t58 in #t57{core::Iterable<dynamic>}) {
           final core::int #t59 = #t58 as{TypeError,ForNonNullableByDefault} core::int;
-          #t56.{core::Set::add}(#t59);
+          #t56.{core::Set::add}{Invariant}(#t59);
         }
     }
   } =>#t56, block {
@@ -350,7 +350,7 @@
       if(!#t61.{core::Object::==}(null))
         for (final dynamic #t62 in #t61{core::Iterable<dynamic>}) {
           final core::int #t63 = #t62 as{TypeError,ForNonNullableByDefault} core::int;
-          #t60.{core::Set::add}(#t63);
+          #t60.{core::Set::add}{Invariant}(#t63);
         }
     }
   } =>#t60, block {
@@ -360,7 +360,7 @@
       if(!#t65.{core::Object::==}(null))
         for (final dynamic #t66 in #t65{core::Iterable<dynamic>}) {
           final core::int #t67 = #t66 as{TypeError,ForNonNullableByDefault} core::int;
-          #t64.{core::Set::add}(#t67);
+          #t64.{core::Set::add}{Invariant}(#t67);
         }
     }
   } =>#t64, block {
@@ -369,7 +369,7 @@
       final core::Map<core::int, core::int>? #t69 = d;
       if(!#t69.{core::Object::==}(null))
         for (final core::MapEntry<core::int, core::int> #t70 in #t69{core::Map<core::int, core::int>}.{core::Map::entries})
-          #t68.{core::Map::[]=}(#t70.{core::MapEntry::key}, #t70.{core::MapEntry::value});
+          #t68.{core::Map::[]=}{Invariant}(#t70.{core::MapEntry::key}, #t70.{core::MapEntry::value});
     }
   } =>#t68, block {
     final core::Set<core::int> #t71 = col::LinkedHashSet::•<core::int>();
@@ -378,7 +378,7 @@
       if(!#t72.{core::Object::==}(null))
         for (final dynamic #t73 in #t72{core::Iterable<dynamic>}) {
           final core::int #t74 = #t73 as{TypeError,ForNonNullableByDefault} core::int;
-          #t71.{core::Set::add}(#t74);
+          #t71.{core::Set::add}{Invariant}(#t74);
         }
     }
   } =>#t71, block {
@@ -388,7 +388,7 @@
       if(!#t76.{core::Object::==}(null))
         for (final dynamic #t77 in #t76{core::Iterable<dynamic>}) {
           final core::int #t78 = #t77 as{TypeError,ForNonNullableByDefault} core::int;
-          #t75.{core::Set::add}(#t78);
+          #t75.{core::Set::add}{Invariant}(#t78);
         }
     }
   } =>#t75, block {
@@ -398,7 +398,7 @@
       if(!#t80.{core::Object::==}(null))
         for (final dynamic #t81 in #t80{core::Iterable<dynamic>}) {
           final core::int #t82 = #t81 as{TypeError,ForNonNullableByDefault} core::int;
-          #t79.{core::Set::add}(#t82);
+          #t79.{core::Set::add}{Invariant}(#t82);
         }
     }
   } =>#t79, block {
@@ -407,7 +407,7 @@
       final core::Map<core::int, core::int>? #t84 = d;
       if(!#t84.{core::Object::==}(null))
         for (final core::MapEntry<core::int, core::int> #t85 in #t84{core::Map<core::int, core::int>}.{core::Map::entries})
-          #t83.{core::Map::[]=}(#t85.{core::MapEntry::key}, #t85.{core::MapEntry::value});
+          #t83.{core::Map::[]=}{Invariant}(#t85.{core::MapEntry::key}, #t85.{core::MapEntry::value});
     }
   } =>#t83, block {
     final core::Set<core::int> #t86 = col::LinkedHashSet::•<core::int>();
@@ -416,7 +416,7 @@
       if(!#t87.{core::Object::==}(null))
         for (final dynamic #t88 in #t87{core::Iterable<dynamic>}) {
           final core::int #t89 = #t88 as{TypeError,ForNonNullableByDefault} core::int;
-          #t86.{core::Set::add}(#t89);
+          #t86.{core::Set::add}{Invariant}(#t89);
         }
     }
   } =>#t86, block {
@@ -426,7 +426,7 @@
       if(!#t91.{core::Object::==}(null))
         for (final dynamic #t92 in #t91{core::Iterable<dynamic>}) {
           final core::int #t93 = #t92 as{TypeError,ForNonNullableByDefault} core::int;
-          #t90.{core::Set::add}(#t93);
+          #t90.{core::Set::add}{Invariant}(#t93);
         }
     }
   } =>#t90, block {
@@ -436,7 +436,7 @@
       if(!#t95.{core::Object::==}(null))
         for (final dynamic #t96 in #t95{core::Iterable<dynamic>}) {
           final core::int #t97 = #t96 as{TypeError,ForNonNullableByDefault} core::int;
-          #t94.{core::Set::add}(#t97);
+          #t94.{core::Set::add}{Invariant}(#t97);
         }
     }
   } =>#t94, block {
@@ -445,7 +445,7 @@
       final core::Map<core::int, core::int>? #t99 = d;
       if(!#t99.{core::Object::==}(null))
         for (final core::MapEntry<core::int, core::int> #t100 in #t99{core::Map<core::int, core::int>}.{core::Map::entries})
-          #t98.{core::Map::[]=}(#t100.{core::MapEntry::key}, #t100.{core::MapEntry::value});
+          #t98.{core::Map::[]=}{Invariant}(#t100.{core::MapEntry::key}, #t100.{core::MapEntry::value});
     }
   } =>#t98];
 }
@@ -456,7 +456,7 @@
     {...x}, // Error.
         ^") {
       final core::int #t103 = #t102 as{TypeError,ForNonNullableByDefault} core::int;
-      #t101.{core::Set::add}(#t103);
+      #t101.{core::Set::add}{Invariant}(#t103);
     }
   } =>#t101, block {
     final core::Set<core::int> #t104 = col::LinkedHashSet::•<core::int>();
@@ -464,7 +464,7 @@
     {...y}, // Error.
         ^") {
       final core::int #t106 = #t105 as{TypeError,ForNonNullableByDefault} core::int;
-      #t104.{core::Set::add}(#t106);
+      #t104.{core::Set::add}{Invariant}(#t106);
     }
   } =>#t104, block {
     final core::Set<core::int> #t107 = col::LinkedHashSet::•<core::int>();
@@ -472,7 +472,7 @@
     {...z}, // Error.
         ^") {
       final core::int #t109 = #t108 as{TypeError,ForNonNullableByDefault} core::int;
-      #t107.{core::Set::add}(#t109);
+      #t107.{core::Set::add}{Invariant}(#t109);
     }
   } =>#t107, <core::int, core::int>{invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:53:9: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {...w}, // Error.
@@ -480,7 +480,7 @@
     <int, int>{...x}, // Error.
                   ^": null}, block {
     final core::Set<core::int> #t110 = col::LinkedHashSet::•<core::int>();
-    #t110.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:55:14: Error: Unexpected type 'W' of a spread.  Expected 'dynamic' or an Iterable.
+    #t110.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:55:14: Error: Unexpected type 'W' of a spread.  Expected 'dynamic' or an Iterable.
     <int>{...w}, // Error.
              ^");
   } =>#t110, block {
@@ -490,7 +490,7 @@
     {if (condition) ...x}, // Error.
                        ^") {
         final core::int #t113 = #t112 as{TypeError,ForNonNullableByDefault} core::int;
-        #t111.{core::Set::add}(#t113);
+        #t111.{core::Set::add}{Invariant}(#t113);
       }
   } =>#t111, block {
     final core::Set<core::int> #t114 = col::LinkedHashSet::•<core::int>();
@@ -499,7 +499,7 @@
     {if (condition) ...y}, // Error.
                        ^") {
         final core::int #t116 = #t115 as{TypeError,ForNonNullableByDefault} core::int;
-        #t114.{core::Set::add}(#t116);
+        #t114.{core::Set::add}{Invariant}(#t116);
       }
   } =>#t114, block {
     final core::Set<core::int> #t117 = col::LinkedHashSet::•<core::int>();
@@ -508,12 +508,12 @@
     {if (condition) ...z}, // Error.
                        ^") {
         final core::int #t119 = #t118 as{TypeError,ForNonNullableByDefault} core::int;
-        #t117.{core::Set::add}(#t119);
+        #t117.{core::Set::add}{Invariant}(#t119);
       }
   } =>#t117, block {
     final core::Map<core::int, core::int> #t120 = <core::int, core::int>{};
     if(condition)
-      #t120.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:59:24: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t120.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:59:24: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {if (condition) ...w}, // Error.
                        ^", null);
   } =>#t120, block {
@@ -523,7 +523,7 @@
     {for (dynamic e in iterable) ...x}, // Error.
                                     ^") {
         final core::int #t123 = #t122 as{TypeError,ForNonNullableByDefault} core::int;
-        #t121.{core::Set::add}(#t123);
+        #t121.{core::Set::add}{Invariant}(#t123);
       }
   } =>#t121, block {
     final core::Set<core::int> #t124 = col::LinkedHashSet::•<core::int>();
@@ -532,7 +532,7 @@
     {for (dynamic e in iterable) ...y}, // Error.
                                     ^") {
         final core::int #t126 = #t125 as{TypeError,ForNonNullableByDefault} core::int;
-        #t124.{core::Set::add}(#t126);
+        #t124.{core::Set::add}{Invariant}(#t126);
       }
   } =>#t124, block {
     final core::Set<core::int> #t127 = col::LinkedHashSet::•<core::int>();
@@ -541,12 +541,12 @@
     {for (dynamic e in iterable) ...z}, // Error.
                                     ^") {
         final core::int #t129 = #t128 as{TypeError,ForNonNullableByDefault} core::int;
-        #t127.{core::Set::add}(#t129);
+        #t127.{core::Set::add}{Invariant}(#t129);
       }
   } =>#t127, block {
     final core::Map<core::int, core::int> #t130 = <core::int, core::int>{};
     for (dynamic e in iterable)
-      #t130.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:63:37: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t130.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:63:37: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {for (dynamic e in iterable) ...w}, // Error.
                                     ^", null);
   } =>#t130, block {
@@ -556,7 +556,7 @@
     {for (int i = 0; i < 42; ++i) ...x}, // Error.
                                      ^") {
         final core::int #t133 = #t132 as{TypeError,ForNonNullableByDefault} core::int;
-        #t131.{core::Set::add}(#t133);
+        #t131.{core::Set::add}{Invariant}(#t133);
       }
   } =>#t131, block {
     final core::Set<core::int> #t134 = col::LinkedHashSet::•<core::int>();
@@ -565,7 +565,7 @@
     {for (int i = 0; i < 42; ++i) ...y}, // Error.
                                      ^") {
         final core::int #t136 = #t135 as{TypeError,ForNonNullableByDefault} core::int;
-        #t134.{core::Set::add}(#t136);
+        #t134.{core::Set::add}{Invariant}(#t136);
       }
   } =>#t134, block {
     final core::Set<core::int> #t137 = col::LinkedHashSet::•<core::int>();
@@ -574,12 +574,12 @@
     {for (int i = 0; i < 42; ++i) ...z}, // Error.
                                      ^") {
         final core::int #t139 = #t138 as{TypeError,ForNonNullableByDefault} core::int;
-        #t137.{core::Set::add}(#t139);
+        #t137.{core::Set::add}{Invariant}(#t139);
       }
   } =>#t137, block {
     final core::Map<core::int, core::int> #t140 = <core::int, core::int>{};
     for (core::int i = 0; i.{core::num::<}(42); i = i.{core::num::+}(1))
-      #t140.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:67:38: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t140.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:67:38: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {for (int i = 0; i < 42; ++i) ...w}, // Error.
                                      ^", null);
   } =>#t140, block {
@@ -588,7 +588,7 @@
     if(!#t142.{core::Object::==}(null))
       for (final dynamic #t143 in #t142{core::Iterable<dynamic>}) {
         final core::int #t144 = #t143 as{TypeError,ForNonNullableByDefault} core::int;
-        #t141.{core::Set::add}(#t144);
+        #t141.{core::Set::add}{Invariant}(#t144);
       }
   } =>#t141, block {
     final core::Set<core::int> #t145 = col::LinkedHashSet::•<core::int>();
@@ -596,7 +596,7 @@
     if(!#t146.{core::Object::==}(null))
       for (final dynamic #t147 in #t146{core::Iterable<dynamic>}) {
         final core::int #t148 = #t147 as{TypeError,ForNonNullableByDefault} core::int;
-        #t145.{core::Set::add}(#t148);
+        #t145.{core::Set::add}{Invariant}(#t148);
       }
   } =>#t145, block {
     final core::Set<core::int> #t149 = col::LinkedHashSet::•<core::int>();
@@ -604,14 +604,14 @@
     if(!#t150.{core::Object::==}(null))
       for (final dynamic #t151 in #t150{core::Iterable<dynamic>}) {
         final core::int #t152 = #t151 as{TypeError,ForNonNullableByDefault} core::int;
-        #t149.{core::Set::add}(#t152);
+        #t149.{core::Set::add}{Invariant}(#t152);
       }
   } =>#t149, block {
     final core::Map<core::int, core::int> #t153 = <core::int, core::int>{};
     final core::Map<core::int, core::int>? #t154 = w;
     if(!#t154.{core::Object::==}(null))
       for (final core::MapEntry<core::int, core::int> #t155 in #t154{core::Map<core::int, core::int>}.{core::Map::entries})
-        #t153.{core::Map::[]=}(#t155.{core::MapEntry::key}, #t155.{core::MapEntry::value});
+        #t153.{core::Map::[]=}{Invariant}(#t155.{core::MapEntry::key}, #t155.{core::MapEntry::value});
   } =>#t153, block {
     final core::Set<core::int> #t156 = col::LinkedHashSet::•<core::int>();
     if(condition) {
@@ -619,7 +619,7 @@
       if(!#t157.{core::Object::==}(null))
         for (final dynamic #t158 in #t157{core::Iterable<dynamic>}) {
           final core::int #t159 = #t158 as{TypeError,ForNonNullableByDefault} core::int;
-          #t156.{core::Set::add}(#t159);
+          #t156.{core::Set::add}{Invariant}(#t159);
         }
     }
   } =>#t156, block {
@@ -629,7 +629,7 @@
       if(!#t161.{core::Object::==}(null))
         for (final dynamic #t162 in #t161{core::Iterable<dynamic>}) {
           final core::int #t163 = #t162 as{TypeError,ForNonNullableByDefault} core::int;
-          #t160.{core::Set::add}(#t163);
+          #t160.{core::Set::add}{Invariant}(#t163);
         }
     }
   } =>#t160, block {
@@ -639,7 +639,7 @@
       if(!#t165.{core::Object::==}(null))
         for (final dynamic #t166 in #t165{core::Iterable<dynamic>}) {
           final core::int #t167 = #t166 as{TypeError,ForNonNullableByDefault} core::int;
-          #t164.{core::Set::add}(#t167);
+          #t164.{core::Set::add}{Invariant}(#t167);
         }
     }
   } =>#t164, block {
@@ -648,7 +648,7 @@
       final core::Map<core::int, core::int>? #t169 = w;
       if(!#t169.{core::Object::==}(null))
         for (final core::MapEntry<core::int, core::int> #t170 in #t169{core::Map<core::int, core::int>}.{core::Map::entries})
-          #t168.{core::Map::[]=}(#t170.{core::MapEntry::key}, #t170.{core::MapEntry::value});
+          #t168.{core::Map::[]=}{Invariant}(#t170.{core::MapEntry::key}, #t170.{core::MapEntry::value});
     }
   } =>#t168, block {
     final core::Set<core::int> #t171 = col::LinkedHashSet::•<core::int>();
@@ -657,7 +657,7 @@
       if(!#t172.{core::Object::==}(null))
         for (final dynamic #t173 in #t172{core::Iterable<dynamic>}) {
           final core::int #t174 = #t173 as{TypeError,ForNonNullableByDefault} core::int;
-          #t171.{core::Set::add}(#t174);
+          #t171.{core::Set::add}{Invariant}(#t174);
         }
     }
   } =>#t171, block {
@@ -667,7 +667,7 @@
       if(!#t176.{core::Object::==}(null))
         for (final dynamic #t177 in #t176{core::Iterable<dynamic>}) {
           final core::int #t178 = #t177 as{TypeError,ForNonNullableByDefault} core::int;
-          #t175.{core::Set::add}(#t178);
+          #t175.{core::Set::add}{Invariant}(#t178);
         }
     }
   } =>#t175, block {
@@ -677,7 +677,7 @@
       if(!#t180.{core::Object::==}(null))
         for (final dynamic #t181 in #t180{core::Iterable<dynamic>}) {
           final core::int #t182 = #t181 as{TypeError,ForNonNullableByDefault} core::int;
-          #t179.{core::Set::add}(#t182);
+          #t179.{core::Set::add}{Invariant}(#t182);
         }
     }
   } =>#t179, block {
@@ -686,7 +686,7 @@
       final core::Map<core::int, core::int>? #t184 = w;
       if(!#t184.{core::Object::==}(null))
         for (final core::MapEntry<core::int, core::int> #t185 in #t184{core::Map<core::int, core::int>}.{core::Map::entries})
-          #t183.{core::Map::[]=}(#t185.{core::MapEntry::key}, #t185.{core::MapEntry::value});
+          #t183.{core::Map::[]=}{Invariant}(#t185.{core::MapEntry::key}, #t185.{core::MapEntry::value});
     }
   } =>#t183, block {
     final core::Set<core::int> #t186 = col::LinkedHashSet::•<core::int>();
@@ -695,7 +695,7 @@
       if(!#t187.{core::Object::==}(null))
         for (final dynamic #t188 in #t187{core::Iterable<dynamic>}) {
           final core::int #t189 = #t188 as{TypeError,ForNonNullableByDefault} core::int;
-          #t186.{core::Set::add}(#t189);
+          #t186.{core::Set::add}{Invariant}(#t189);
         }
     }
   } =>#t186, block {
@@ -705,7 +705,7 @@
       if(!#t191.{core::Object::==}(null))
         for (final dynamic #t192 in #t191{core::Iterable<dynamic>}) {
           final core::int #t193 = #t192 as{TypeError,ForNonNullableByDefault} core::int;
-          #t190.{core::Set::add}(#t193);
+          #t190.{core::Set::add}{Invariant}(#t193);
         }
     }
   } =>#t190, block {
@@ -715,7 +715,7 @@
       if(!#t195.{core::Object::==}(null))
         for (final dynamic #t196 in #t195{core::Iterable<dynamic>}) {
           final core::int #t197 = #t196 as{TypeError,ForNonNullableByDefault} core::int;
-          #t194.{core::Set::add}(#t197);
+          #t194.{core::Set::add}{Invariant}(#t197);
         }
     }
   } =>#t194, block {
@@ -724,7 +724,7 @@
       final core::Map<core::int, core::int>? #t199 = w;
       if(!#t199.{core::Object::==}(null))
         for (final core::MapEntry<core::int, core::int> #t200 in #t199{core::Map<core::int, core::int>}.{core::Map::entries})
-          #t198.{core::Map::[]=}(#t200.{core::MapEntry::key}, #t200.{core::MapEntry::value});
+          #t198.{core::Map::[]=}{Invariant}(#t200.{core::MapEntry::key}, #t200.{core::MapEntry::value});
     }
   } =>#t198];
 }
diff --git a/pkg/front_end/testcases/nnbd/issue43495.dart.strong.transformed.expect b/pkg/front_end/testcases/nnbd/issue43495.dart.strong.transformed.expect
index 2c74f65..e3ffc57 100644
--- a/pkg/front_end/testcases/nnbd/issue43495.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/nnbd/issue43495.dart.strong.transformed.expect
@@ -175,7 +175,7 @@
     {...a}, // Error.
         ^") {
       final core::int #t3 = #t2 as{TypeError,ForNonNullableByDefault} core::int;
-      #t1.{core::Set::add}(#t3);
+      #t1.{core::Set::add}{Invariant}(#t3);
     }
   } =>#t1, block {
     final core::Set<core::int> #t4 = new col::_CompactLinkedHashSet::•<core::int>();
@@ -183,7 +183,7 @@
     {...b}, // Error.
         ^") {
       final core::int #t6 = #t5 as{TypeError,ForNonNullableByDefault} core::int;
-      #t4.{core::Set::add}(#t6);
+      #t4.{core::Set::add}{Invariant}(#t6);
     }
   } =>#t4, block {
     final core::Set<core::int> #t7 = new col::_CompactLinkedHashSet::•<core::int>();
@@ -191,7 +191,7 @@
     {...c}, // Error.
         ^") {
       final core::int #t9 = #t8 as{TypeError,ForNonNullableByDefault} core::int;
-      #t7.{core::Set::add}(#t9);
+      #t7.{core::Set::add}{Invariant}(#t9);
     }
   } =>#t7, <core::int, core::int>{invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:11:9: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {...d}, // Error.
@@ -200,7 +200,7 @@
     <int, int>{...a}, // Error.
                   ^": null}, block {
     final core::Set<core::int> #t10 = new col::_CompactLinkedHashSet::•<core::int>();
-    #t10.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:13:14: Error: Unexpected type 'Map<int, int>?' of a spread.  Expected 'dynamic' or an Iterable.
+    #t10.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:13:14: Error: Unexpected type 'Map<int, int>?' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
     <int>{...d}, // Error.
              ^");
@@ -211,7 +211,7 @@
     {if (condition) ...a}, // Error.
                        ^") {
         final core::int #t13 = #t12 as{TypeError,ForNonNullableByDefault} core::int;
-        #t11.{core::Set::add}(#t13);
+        #t11.{core::Set::add}{Invariant}(#t13);
       }
   } =>#t11, block {
     final core::Set<core::int> #t14 = new col::_CompactLinkedHashSet::•<core::int>();
@@ -220,7 +220,7 @@
     {if (condition) ...b}, // Error.
                        ^") {
         final core::int #t16 = #t15 as{TypeError,ForNonNullableByDefault} core::int;
-        #t14.{core::Set::add}(#t16);
+        #t14.{core::Set::add}{Invariant}(#t16);
       }
   } =>#t14, block {
     final core::Set<core::int> #t17 = new col::_CompactLinkedHashSet::•<core::int>();
@@ -229,12 +229,12 @@
     {if (condition) ...c}, // Error.
                        ^") {
         final core::int #t19 = #t18 as{TypeError,ForNonNullableByDefault} core::int;
-        #t17.{core::Set::add}(#t19);
+        #t17.{core::Set::add}{Invariant}(#t19);
       }
   } =>#t17, block {
     final core::Map<core::int, core::int> #t20 = <core::int, core::int>{};
     if(condition)
-      #t20.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:17:24: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t20.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:17:24: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {if (condition) ...d}, // Error.
                        ^", null);
   } =>#t20, block {
@@ -247,7 +247,7 @@
     {for (dynamic e in iterable) ...a}, // Error.
                                     ^") {
           final core::int #t23 = #t22 as{TypeError,ForNonNullableByDefault} core::int;
-          #t21.{core::Set::add}(#t23);
+          #t21.{core::Set::add}{Invariant}(#t23);
         }
       }
     }
@@ -261,7 +261,7 @@
     {for (dynamic e in iterable) ...b}, // Error.
                                     ^") {
           final core::int #t26 = #t25 as{TypeError,ForNonNullableByDefault} core::int;
-          #t24.{core::Set::add}(#t26);
+          #t24.{core::Set::add}{Invariant}(#t26);
         }
       }
     }
@@ -275,7 +275,7 @@
     {for (dynamic e in iterable) ...c}, // Error.
                                     ^") {
           final core::int #t29 = #t28 as{TypeError,ForNonNullableByDefault} core::int;
-          #t27.{core::Set::add}(#t29);
+          #t27.{core::Set::add}{Invariant}(#t29);
         }
       }
     }
@@ -285,7 +285,7 @@
       core::Iterator<dynamic> :sync-for-iterator = iterable.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         dynamic e = :sync-for-iterator.{core::Iterator::current};
-        #t30.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:21:37: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+        #t30.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:21:37: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {for (dynamic e in iterable) ...d}, // Error.
                                     ^", null);
       }
@@ -297,7 +297,7 @@
     {for (int i = 0; i < 42; ++i) ...a}, // Error.
                                      ^") {
         final core::int #t33 = #t32 as{TypeError,ForNonNullableByDefault} core::int;
-        #t31.{core::Set::add}(#t33);
+        #t31.{core::Set::add}{Invariant}(#t33);
       }
   } =>#t31, block {
     final core::Set<core::int> #t34 = new col::_CompactLinkedHashSet::•<core::int>();
@@ -306,7 +306,7 @@
     {for (int i = 0; i < 42; ++i) ...b}, // Error.
                                      ^") {
         final core::int #t36 = #t35 as{TypeError,ForNonNullableByDefault} core::int;
-        #t34.{core::Set::add}(#t36);
+        #t34.{core::Set::add}{Invariant}(#t36);
       }
   } =>#t34, block {
     final core::Set<core::int> #t37 = new col::_CompactLinkedHashSet::•<core::int>();
@@ -315,12 +315,12 @@
     {for (int i = 0; i < 42; ++i) ...c}, // Error.
                                      ^") {
         final core::int #t39 = #t38 as{TypeError,ForNonNullableByDefault} core::int;
-        #t37.{core::Set::add}(#t39);
+        #t37.{core::Set::add}{Invariant}(#t39);
       }
   } =>#t37, block {
     final core::Map<core::int, core::int> #t40 = <core::int, core::int>{};
     for (core::int i = 0; i.{core::num::<}(42); i = i.{core::num::+}(1))
-      #t40.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:25:38: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t40.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:25:38: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {for (int i = 0; i < 42; ++i) ...d}, // Error.
                                      ^", null);
   } =>#t40, block {
@@ -332,7 +332,7 @@
         final dynamic #t43 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int #t44 = #t43 as{TypeError,ForNonNullableByDefault} core::int;
-          #t41.{core::Set::add}(#t44);
+          #t41.{core::Set::add}{Invariant}(#t44);
         }
       }
     }
@@ -345,7 +345,7 @@
         final dynamic #t47 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int #t48 = #t47 as{TypeError,ForNonNullableByDefault} core::int;
-          #t45.{core::Set::add}(#t48);
+          #t45.{core::Set::add}{Invariant}(#t48);
         }
       }
     }
@@ -358,7 +358,7 @@
         final dynamic #t51 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int #t52 = #t51 as{TypeError,ForNonNullableByDefault} core::int;
-          #t49.{core::Set::add}(#t52);
+          #t49.{core::Set::add}{Invariant}(#t52);
         }
       }
     }
@@ -369,7 +369,7 @@
       core::Iterator<core::MapEntry<core::int, core::int>> :sync-for-iterator = #t54{core::Map<core::int, core::int>}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::int, core::int> #t55 = :sync-for-iterator.{core::Iterator::current};
-        #t53.{core::Map::[]=}(#t55.{core::MapEntry::key}, #t55.{core::MapEntry::value});
+        #t53.{core::Map::[]=}{Invariant}(#t55.{core::MapEntry::key}, #t55.{core::MapEntry::value});
       }
     }
   } =>#t53, block {
@@ -382,7 +382,7 @@
           final dynamic #t58 = :sync-for-iterator.{core::Iterator::current};
           {
             final core::int #t59 = #t58 as{TypeError,ForNonNullableByDefault} core::int;
-            #t56.{core::Set::add}(#t59);
+            #t56.{core::Set::add}{Invariant}(#t59);
           }
         }
       }
@@ -397,7 +397,7 @@
           final dynamic #t62 = :sync-for-iterator.{core::Iterator::current};
           {
             final core::int #t63 = #t62 as{TypeError,ForNonNullableByDefault} core::int;
-            #t60.{core::Set::add}(#t63);
+            #t60.{core::Set::add}{Invariant}(#t63);
           }
         }
       }
@@ -412,7 +412,7 @@
           final dynamic #t66 = :sync-for-iterator.{core::Iterator::current};
           {
             final core::int #t67 = #t66 as{TypeError,ForNonNullableByDefault} core::int;
-            #t64.{core::Set::add}(#t67);
+            #t64.{core::Set::add}{Invariant}(#t67);
           }
         }
       }
@@ -425,7 +425,7 @@
         core::Iterator<core::MapEntry<core::int, core::int>> :sync-for-iterator = #t69{core::Map<core::int, core::int>}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::int, core::int> #t70 = :sync-for-iterator.{core::Iterator::current};
-          #t68.{core::Map::[]=}(#t70.{core::MapEntry::key}, #t70.{core::MapEntry::value});
+          #t68.{core::Map::[]=}{Invariant}(#t70.{core::MapEntry::key}, #t70.{core::MapEntry::value});
         }
       }
     }
@@ -443,7 +443,7 @@
               final dynamic #t73 = :sync-for-iterator.{core::Iterator::current};
               {
                 final core::int #t74 = #t73 as{TypeError,ForNonNullableByDefault} core::int;
-                #t71.{core::Set::add}(#t74);
+                #t71.{core::Set::add}{Invariant}(#t74);
               }
             }
           }
@@ -464,7 +464,7 @@
               final dynamic #t77 = :sync-for-iterator.{core::Iterator::current};
               {
                 final core::int #t78 = #t77 as{TypeError,ForNonNullableByDefault} core::int;
-                #t75.{core::Set::add}(#t78);
+                #t75.{core::Set::add}{Invariant}(#t78);
               }
             }
           }
@@ -485,7 +485,7 @@
               final dynamic #t81 = :sync-for-iterator.{core::Iterator::current};
               {
                 final core::int #t82 = #t81 as{TypeError,ForNonNullableByDefault} core::int;
-                #t79.{core::Set::add}(#t82);
+                #t79.{core::Set::add}{Invariant}(#t82);
               }
             }
           }
@@ -504,7 +504,7 @@
             core::Iterator<core::MapEntry<core::int, core::int>> :sync-for-iterator = #t84{core::Map<core::int, core::int>}.{core::Map::entries}.{core::Iterable::iterator};
             for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
               final core::MapEntry<core::int, core::int> #t85 = :sync-for-iterator.{core::Iterator::current};
-              #t83.{core::Map::[]=}(#t85.{core::MapEntry::key}, #t85.{core::MapEntry::value});
+              #t83.{core::Map::[]=}{Invariant}(#t85.{core::MapEntry::key}, #t85.{core::MapEntry::value});
             }
           }
         }
@@ -520,7 +520,7 @@
           final dynamic #t88 = :sync-for-iterator.{core::Iterator::current};
           {
             final core::int #t89 = #t88 as{TypeError,ForNonNullableByDefault} core::int;
-            #t86.{core::Set::add}(#t89);
+            #t86.{core::Set::add}{Invariant}(#t89);
           }
         }
       }
@@ -535,7 +535,7 @@
           final dynamic #t92 = :sync-for-iterator.{core::Iterator::current};
           {
             final core::int #t93 = #t92 as{TypeError,ForNonNullableByDefault} core::int;
-            #t90.{core::Set::add}(#t93);
+            #t90.{core::Set::add}{Invariant}(#t93);
           }
         }
       }
@@ -550,7 +550,7 @@
           final dynamic #t96 = :sync-for-iterator.{core::Iterator::current};
           {
             final core::int #t97 = #t96 as{TypeError,ForNonNullableByDefault} core::int;
-            #t94.{core::Set::add}(#t97);
+            #t94.{core::Set::add}{Invariant}(#t97);
           }
         }
       }
@@ -563,7 +563,7 @@
         core::Iterator<core::MapEntry<core::int, core::int>> :sync-for-iterator = #t99{core::Map<core::int, core::int>}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::int, core::int> #t100 = :sync-for-iterator.{core::Iterator::current};
-          #t98.{core::Map::[]=}(#t100.{core::MapEntry::key}, #t100.{core::MapEntry::value});
+          #t98.{core::Map::[]=}{Invariant}(#t100.{core::MapEntry::key}, #t100.{core::MapEntry::value});
         }
       }
     }
@@ -576,7 +576,7 @@
     {...x}, // Error.
         ^") {
       final core::int #t103 = #t102 as{TypeError,ForNonNullableByDefault} core::int;
-      #t101.{core::Set::add}(#t103);
+      #t101.{core::Set::add}{Invariant}(#t103);
     }
   } =>#t101, block {
     final core::Set<core::int> #t104 = new col::_CompactLinkedHashSet::•<core::int>();
@@ -584,7 +584,7 @@
     {...y}, // Error.
         ^") {
       final core::int #t106 = #t105 as{TypeError,ForNonNullableByDefault} core::int;
-      #t104.{core::Set::add}(#t106);
+      #t104.{core::Set::add}{Invariant}(#t106);
     }
   } =>#t104, block {
     final core::Set<core::int> #t107 = new col::_CompactLinkedHashSet::•<core::int>();
@@ -592,7 +592,7 @@
     {...z}, // Error.
         ^") {
       final core::int #t109 = #t108 as{TypeError,ForNonNullableByDefault} core::int;
-      #t107.{core::Set::add}(#t109);
+      #t107.{core::Set::add}{Invariant}(#t109);
     }
   } =>#t107, <core::int, core::int>{invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:53:9: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {...w}, // Error.
@@ -600,7 +600,7 @@
     <int, int>{...x}, // Error.
                   ^": null}, block {
     final core::Set<core::int> #t110 = new col::_CompactLinkedHashSet::•<core::int>();
-    #t110.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:55:14: Error: Unexpected type 'W' of a spread.  Expected 'dynamic' or an Iterable.
+    #t110.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:55:14: Error: Unexpected type 'W' of a spread.  Expected 'dynamic' or an Iterable.
     <int>{...w}, // Error.
              ^");
   } =>#t110, block {
@@ -610,7 +610,7 @@
     {if (condition) ...x}, // Error.
                        ^") {
         final core::int #t113 = #t112 as{TypeError,ForNonNullableByDefault} core::int;
-        #t111.{core::Set::add}(#t113);
+        #t111.{core::Set::add}{Invariant}(#t113);
       }
   } =>#t111, block {
     final core::Set<core::int> #t114 = new col::_CompactLinkedHashSet::•<core::int>();
@@ -619,7 +619,7 @@
     {if (condition) ...y}, // Error.
                        ^") {
         final core::int #t116 = #t115 as{TypeError,ForNonNullableByDefault} core::int;
-        #t114.{core::Set::add}(#t116);
+        #t114.{core::Set::add}{Invariant}(#t116);
       }
   } =>#t114, block {
     final core::Set<core::int> #t117 = new col::_CompactLinkedHashSet::•<core::int>();
@@ -628,12 +628,12 @@
     {if (condition) ...z}, // Error.
                        ^") {
         final core::int #t119 = #t118 as{TypeError,ForNonNullableByDefault} core::int;
-        #t117.{core::Set::add}(#t119);
+        #t117.{core::Set::add}{Invariant}(#t119);
       }
   } =>#t117, block {
     final core::Map<core::int, core::int> #t120 = <core::int, core::int>{};
     if(condition)
-      #t120.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:59:24: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t120.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:59:24: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {if (condition) ...w}, // Error.
                        ^", null);
   } =>#t120, block {
@@ -646,7 +646,7 @@
     {for (dynamic e in iterable) ...x}, // Error.
                                     ^") {
           final core::int #t123 = #t122 as{TypeError,ForNonNullableByDefault} core::int;
-          #t121.{core::Set::add}(#t123);
+          #t121.{core::Set::add}{Invariant}(#t123);
         }
       }
     }
@@ -660,7 +660,7 @@
     {for (dynamic e in iterable) ...y}, // Error.
                                     ^") {
           final core::int #t126 = #t125 as{TypeError,ForNonNullableByDefault} core::int;
-          #t124.{core::Set::add}(#t126);
+          #t124.{core::Set::add}{Invariant}(#t126);
         }
       }
     }
@@ -674,7 +674,7 @@
     {for (dynamic e in iterable) ...z}, // Error.
                                     ^") {
           final core::int #t129 = #t128 as{TypeError,ForNonNullableByDefault} core::int;
-          #t127.{core::Set::add}(#t129);
+          #t127.{core::Set::add}{Invariant}(#t129);
         }
       }
     }
@@ -684,7 +684,7 @@
       core::Iterator<dynamic> :sync-for-iterator = iterable.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         dynamic e = :sync-for-iterator.{core::Iterator::current};
-        #t130.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:63:37: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+        #t130.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:63:37: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {for (dynamic e in iterable) ...w}, // Error.
                                     ^", null);
       }
@@ -696,7 +696,7 @@
     {for (int i = 0; i < 42; ++i) ...x}, // Error.
                                      ^") {
         final core::int #t133 = #t132 as{TypeError,ForNonNullableByDefault} core::int;
-        #t131.{core::Set::add}(#t133);
+        #t131.{core::Set::add}{Invariant}(#t133);
       }
   } =>#t131, block {
     final core::Set<core::int> #t134 = new col::_CompactLinkedHashSet::•<core::int>();
@@ -705,7 +705,7 @@
     {for (int i = 0; i < 42; ++i) ...y}, // Error.
                                      ^") {
         final core::int #t136 = #t135 as{TypeError,ForNonNullableByDefault} core::int;
-        #t134.{core::Set::add}(#t136);
+        #t134.{core::Set::add}{Invariant}(#t136);
       }
   } =>#t134, block {
     final core::Set<core::int> #t137 = new col::_CompactLinkedHashSet::•<core::int>();
@@ -714,12 +714,12 @@
     {for (int i = 0; i < 42; ++i) ...z}, // Error.
                                      ^") {
         final core::int #t139 = #t138 as{TypeError,ForNonNullableByDefault} core::int;
-        #t137.{core::Set::add}(#t139);
+        #t137.{core::Set::add}{Invariant}(#t139);
       }
   } =>#t137, block {
     final core::Map<core::int, core::int> #t140 = <core::int, core::int>{};
     for (core::int i = 0; i.{core::num::<}(42); i = i.{core::num::+}(1))
-      #t140.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:67:38: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t140.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:67:38: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {for (int i = 0; i < 42; ++i) ...w}, // Error.
                                      ^", null);
   } =>#t140, block {
@@ -731,7 +731,7 @@
         final dynamic #t143 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int #t144 = #t143 as{TypeError,ForNonNullableByDefault} core::int;
-          #t141.{core::Set::add}(#t144);
+          #t141.{core::Set::add}{Invariant}(#t144);
         }
       }
     }
@@ -744,7 +744,7 @@
         final dynamic #t147 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int #t148 = #t147 as{TypeError,ForNonNullableByDefault} core::int;
-          #t145.{core::Set::add}(#t148);
+          #t145.{core::Set::add}{Invariant}(#t148);
         }
       }
     }
@@ -757,7 +757,7 @@
         final dynamic #t151 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int #t152 = #t151 as{TypeError,ForNonNullableByDefault} core::int;
-          #t149.{core::Set::add}(#t152);
+          #t149.{core::Set::add}{Invariant}(#t152);
         }
       }
     }
@@ -768,7 +768,7 @@
       core::Iterator<core::MapEntry<core::int, core::int>> :sync-for-iterator = #t154{core::Map<core::int, core::int>}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::int, core::int> #t155 = :sync-for-iterator.{core::Iterator::current};
-        #t153.{core::Map::[]=}(#t155.{core::MapEntry::key}, #t155.{core::MapEntry::value});
+        #t153.{core::Map::[]=}{Invariant}(#t155.{core::MapEntry::key}, #t155.{core::MapEntry::value});
       }
     }
   } =>#t153, block {
@@ -781,7 +781,7 @@
           final dynamic #t158 = :sync-for-iterator.{core::Iterator::current};
           {
             final core::int #t159 = #t158 as{TypeError,ForNonNullableByDefault} core::int;
-            #t156.{core::Set::add}(#t159);
+            #t156.{core::Set::add}{Invariant}(#t159);
           }
         }
       }
@@ -796,7 +796,7 @@
           final dynamic #t162 = :sync-for-iterator.{core::Iterator::current};
           {
             final core::int #t163 = #t162 as{TypeError,ForNonNullableByDefault} core::int;
-            #t160.{core::Set::add}(#t163);
+            #t160.{core::Set::add}{Invariant}(#t163);
           }
         }
       }
@@ -811,7 +811,7 @@
           final dynamic #t166 = :sync-for-iterator.{core::Iterator::current};
           {
             final core::int #t167 = #t166 as{TypeError,ForNonNullableByDefault} core::int;
-            #t164.{core::Set::add}(#t167);
+            #t164.{core::Set::add}{Invariant}(#t167);
           }
         }
       }
@@ -824,7 +824,7 @@
         core::Iterator<core::MapEntry<core::int, core::int>> :sync-for-iterator = #t169{core::Map<core::int, core::int>}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::int, core::int> #t170 = :sync-for-iterator.{core::Iterator::current};
-          #t168.{core::Map::[]=}(#t170.{core::MapEntry::key}, #t170.{core::MapEntry::value});
+          #t168.{core::Map::[]=}{Invariant}(#t170.{core::MapEntry::key}, #t170.{core::MapEntry::value});
         }
       }
     }
@@ -842,7 +842,7 @@
               final dynamic #t173 = :sync-for-iterator.{core::Iterator::current};
               {
                 final core::int #t174 = #t173 as{TypeError,ForNonNullableByDefault} core::int;
-                #t171.{core::Set::add}(#t174);
+                #t171.{core::Set::add}{Invariant}(#t174);
               }
             }
           }
@@ -863,7 +863,7 @@
               final dynamic #t177 = :sync-for-iterator.{core::Iterator::current};
               {
                 final core::int #t178 = #t177 as{TypeError,ForNonNullableByDefault} core::int;
-                #t175.{core::Set::add}(#t178);
+                #t175.{core::Set::add}{Invariant}(#t178);
               }
             }
           }
@@ -884,7 +884,7 @@
               final dynamic #t181 = :sync-for-iterator.{core::Iterator::current};
               {
                 final core::int #t182 = #t181 as{TypeError,ForNonNullableByDefault} core::int;
-                #t179.{core::Set::add}(#t182);
+                #t179.{core::Set::add}{Invariant}(#t182);
               }
             }
           }
@@ -903,7 +903,7 @@
             core::Iterator<core::MapEntry<core::int, core::int>> :sync-for-iterator = #t184{core::Map<core::int, core::int>}.{core::Map::entries}.{core::Iterable::iterator};
             for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
               final core::MapEntry<core::int, core::int> #t185 = :sync-for-iterator.{core::Iterator::current};
-              #t183.{core::Map::[]=}(#t185.{core::MapEntry::key}, #t185.{core::MapEntry::value});
+              #t183.{core::Map::[]=}{Invariant}(#t185.{core::MapEntry::key}, #t185.{core::MapEntry::value});
             }
           }
         }
@@ -919,7 +919,7 @@
           final dynamic #t188 = :sync-for-iterator.{core::Iterator::current};
           {
             final core::int #t189 = #t188 as{TypeError,ForNonNullableByDefault} core::int;
-            #t186.{core::Set::add}(#t189);
+            #t186.{core::Set::add}{Invariant}(#t189);
           }
         }
       }
@@ -934,7 +934,7 @@
           final dynamic #t192 = :sync-for-iterator.{core::Iterator::current};
           {
             final core::int #t193 = #t192 as{TypeError,ForNonNullableByDefault} core::int;
-            #t190.{core::Set::add}(#t193);
+            #t190.{core::Set::add}{Invariant}(#t193);
           }
         }
       }
@@ -949,7 +949,7 @@
           final dynamic #t196 = :sync-for-iterator.{core::Iterator::current};
           {
             final core::int #t197 = #t196 as{TypeError,ForNonNullableByDefault} core::int;
-            #t194.{core::Set::add}(#t197);
+            #t194.{core::Set::add}{Invariant}(#t197);
           }
         }
       }
@@ -962,7 +962,7 @@
         core::Iterator<core::MapEntry<core::int, core::int>> :sync-for-iterator = #t199{core::Map<core::int, core::int>}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::int, core::int> #t200 = :sync-for-iterator.{core::Iterator::current};
-          #t198.{core::Map::[]=}(#t200.{core::MapEntry::key}, #t200.{core::MapEntry::value});
+          #t198.{core::Map::[]=}{Invariant}(#t200.{core::MapEntry::key}, #t200.{core::MapEntry::value});
         }
       }
     }
diff --git a/pkg/front_end/testcases/nnbd/issue43495.dart.weak.expect b/pkg/front_end/testcases/nnbd/issue43495.dart.weak.expect
index beb8959..0934075 100644
--- a/pkg/front_end/testcases/nnbd/issue43495.dart.weak.expect
+++ b/pkg/front_end/testcases/nnbd/issue43495.dart.weak.expect
@@ -175,7 +175,7 @@
     {...a}, // Error.
         ^") {
       final core::int #t3 = #t2 as{TypeError,ForNonNullableByDefault} core::int;
-      #t1.{core::Set::add}(#t3);
+      #t1.{core::Set::add}{Invariant}(#t3);
     }
   } =>#t1, block {
     final core::Set<core::int> #t4 = col::LinkedHashSet::•<core::int>();
@@ -183,7 +183,7 @@
     {...b}, // Error.
         ^") {
       final core::int #t6 = #t5 as{TypeError,ForNonNullableByDefault} core::int;
-      #t4.{core::Set::add}(#t6);
+      #t4.{core::Set::add}{Invariant}(#t6);
     }
   } =>#t4, block {
     final core::Set<core::int> #t7 = col::LinkedHashSet::•<core::int>();
@@ -191,7 +191,7 @@
     {...c}, // Error.
         ^") {
       final core::int #t9 = #t8 as{TypeError,ForNonNullableByDefault} core::int;
-      #t7.{core::Set::add}(#t9);
+      #t7.{core::Set::add}{Invariant}(#t9);
     }
   } =>#t7, <core::int, core::int>{invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:11:9: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {...d}, // Error.
@@ -200,7 +200,7 @@
     <int, int>{...a}, // Error.
                   ^": null}, block {
     final core::Set<core::int> #t10 = col::LinkedHashSet::•<core::int>();
-    #t10.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:13:14: Error: Unexpected type 'Map<int, int>?' of a spread.  Expected 'dynamic' or an Iterable.
+    #t10.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:13:14: Error: Unexpected type 'Map<int, int>?' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
     <int>{...d}, // Error.
              ^");
@@ -211,7 +211,7 @@
     {if (condition) ...a}, // Error.
                        ^") {
         final core::int #t13 = #t12 as{TypeError,ForNonNullableByDefault} core::int;
-        #t11.{core::Set::add}(#t13);
+        #t11.{core::Set::add}{Invariant}(#t13);
       }
   } =>#t11, block {
     final core::Set<core::int> #t14 = col::LinkedHashSet::•<core::int>();
@@ -220,7 +220,7 @@
     {if (condition) ...b}, // Error.
                        ^") {
         final core::int #t16 = #t15 as{TypeError,ForNonNullableByDefault} core::int;
-        #t14.{core::Set::add}(#t16);
+        #t14.{core::Set::add}{Invariant}(#t16);
       }
   } =>#t14, block {
     final core::Set<core::int> #t17 = col::LinkedHashSet::•<core::int>();
@@ -229,12 +229,12 @@
     {if (condition) ...c}, // Error.
                        ^") {
         final core::int #t19 = #t18 as{TypeError,ForNonNullableByDefault} core::int;
-        #t17.{core::Set::add}(#t19);
+        #t17.{core::Set::add}{Invariant}(#t19);
       }
   } =>#t17, block {
     final core::Map<core::int, core::int> #t20 = <core::int, core::int>{};
     if(condition)
-      #t20.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:17:24: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t20.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:17:24: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {if (condition) ...d}, // Error.
                        ^", null);
   } =>#t20, block {
@@ -244,7 +244,7 @@
     {for (dynamic e in iterable) ...a}, // Error.
                                     ^") {
         final core::int #t23 = #t22 as{TypeError,ForNonNullableByDefault} core::int;
-        #t21.{core::Set::add}(#t23);
+        #t21.{core::Set::add}{Invariant}(#t23);
       }
   } =>#t21, block {
     final core::Set<core::int> #t24 = col::LinkedHashSet::•<core::int>();
@@ -253,7 +253,7 @@
     {for (dynamic e in iterable) ...b}, // Error.
                                     ^") {
         final core::int #t26 = #t25 as{TypeError,ForNonNullableByDefault} core::int;
-        #t24.{core::Set::add}(#t26);
+        #t24.{core::Set::add}{Invariant}(#t26);
       }
   } =>#t24, block {
     final core::Set<core::int> #t27 = col::LinkedHashSet::•<core::int>();
@@ -262,12 +262,12 @@
     {for (dynamic e in iterable) ...c}, // Error.
                                     ^") {
         final core::int #t29 = #t28 as{TypeError,ForNonNullableByDefault} core::int;
-        #t27.{core::Set::add}(#t29);
+        #t27.{core::Set::add}{Invariant}(#t29);
       }
   } =>#t27, block {
     final core::Map<core::int, core::int> #t30 = <core::int, core::int>{};
     for (dynamic e in iterable)
-      #t30.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:21:37: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t30.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:21:37: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {for (dynamic e in iterable) ...d}, // Error.
                                     ^", null);
   } =>#t30, block {
@@ -277,7 +277,7 @@
     {for (int i = 0; i < 42; ++i) ...a}, // Error.
                                      ^") {
         final core::int #t33 = #t32 as{TypeError,ForNonNullableByDefault} core::int;
-        #t31.{core::Set::add}(#t33);
+        #t31.{core::Set::add}{Invariant}(#t33);
       }
   } =>#t31, block {
     final core::Set<core::int> #t34 = col::LinkedHashSet::•<core::int>();
@@ -286,7 +286,7 @@
     {for (int i = 0; i < 42; ++i) ...b}, // Error.
                                      ^") {
         final core::int #t36 = #t35 as{TypeError,ForNonNullableByDefault} core::int;
-        #t34.{core::Set::add}(#t36);
+        #t34.{core::Set::add}{Invariant}(#t36);
       }
   } =>#t34, block {
     final core::Set<core::int> #t37 = col::LinkedHashSet::•<core::int>();
@@ -295,12 +295,12 @@
     {for (int i = 0; i < 42; ++i) ...c}, // Error.
                                      ^") {
         final core::int #t39 = #t38 as{TypeError,ForNonNullableByDefault} core::int;
-        #t37.{core::Set::add}(#t39);
+        #t37.{core::Set::add}{Invariant}(#t39);
       }
   } =>#t37, block {
     final core::Map<core::int, core::int> #t40 = <core::int, core::int>{};
     for (core::int i = 0; i.{core::num::<}(42); i = i.{core::num::+}(1))
-      #t40.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:25:38: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t40.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:25:38: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {for (int i = 0; i < 42; ++i) ...d}, // Error.
                                      ^", null);
   } =>#t40, block {
@@ -309,7 +309,7 @@
     if(!#t42.{core::Object::==}(null))
       for (final dynamic #t43 in #t42{core::Iterable<dynamic>}) {
         final core::int #t44 = #t43 as{TypeError,ForNonNullableByDefault} core::int;
-        #t41.{core::Set::add}(#t44);
+        #t41.{core::Set::add}{Invariant}(#t44);
       }
   } =>#t41, block {
     final core::Set<core::int> #t45 = col::LinkedHashSet::•<core::int>();
@@ -317,7 +317,7 @@
     if(!#t46.{core::Object::==}(null))
       for (final dynamic #t47 in #t46{core::Iterable<dynamic>}) {
         final core::int #t48 = #t47 as{TypeError,ForNonNullableByDefault} core::int;
-        #t45.{core::Set::add}(#t48);
+        #t45.{core::Set::add}{Invariant}(#t48);
       }
   } =>#t45, block {
     final core::Set<core::int> #t49 = col::LinkedHashSet::•<core::int>();
@@ -325,14 +325,14 @@
     if(!#t50.{core::Object::==}(null))
       for (final dynamic #t51 in #t50{core::Iterable<dynamic>}) {
         final core::int #t52 = #t51 as{TypeError,ForNonNullableByDefault} core::int;
-        #t49.{core::Set::add}(#t52);
+        #t49.{core::Set::add}{Invariant}(#t52);
       }
   } =>#t49, block {
     final core::Map<core::int, core::int> #t53 = <core::int, core::int>{};
     final core::Map<core::int, core::int>? #t54 = d;
     if(!#t54.{core::Object::==}(null))
       for (final core::MapEntry<core::int, core::int> #t55 in #t54{core::Map<core::int, core::int>}.{core::Map::entries})
-        #t53.{core::Map::[]=}(#t55.{core::MapEntry::key}, #t55.{core::MapEntry::value});
+        #t53.{core::Map::[]=}{Invariant}(#t55.{core::MapEntry::key}, #t55.{core::MapEntry::value});
   } =>#t53, block {
     final core::Set<core::int> #t56 = col::LinkedHashSet::•<core::int>();
     if(condition) {
@@ -340,7 +340,7 @@
       if(!#t57.{core::Object::==}(null))
         for (final dynamic #t58 in #t57{core::Iterable<dynamic>}) {
           final core::int #t59 = #t58 as{TypeError,ForNonNullableByDefault} core::int;
-          #t56.{core::Set::add}(#t59);
+          #t56.{core::Set::add}{Invariant}(#t59);
         }
     }
   } =>#t56, block {
@@ -350,7 +350,7 @@
       if(!#t61.{core::Object::==}(null))
         for (final dynamic #t62 in #t61{core::Iterable<dynamic>}) {
           final core::int #t63 = #t62 as{TypeError,ForNonNullableByDefault} core::int;
-          #t60.{core::Set::add}(#t63);
+          #t60.{core::Set::add}{Invariant}(#t63);
         }
     }
   } =>#t60, block {
@@ -360,7 +360,7 @@
       if(!#t65.{core::Object::==}(null))
         for (final dynamic #t66 in #t65{core::Iterable<dynamic>}) {
           final core::int #t67 = #t66 as{TypeError,ForNonNullableByDefault} core::int;
-          #t64.{core::Set::add}(#t67);
+          #t64.{core::Set::add}{Invariant}(#t67);
         }
     }
   } =>#t64, block {
@@ -369,7 +369,7 @@
       final core::Map<core::int, core::int>? #t69 = d;
       if(!#t69.{core::Object::==}(null))
         for (final core::MapEntry<core::int, core::int> #t70 in #t69{core::Map<core::int, core::int>}.{core::Map::entries})
-          #t68.{core::Map::[]=}(#t70.{core::MapEntry::key}, #t70.{core::MapEntry::value});
+          #t68.{core::Map::[]=}{Invariant}(#t70.{core::MapEntry::key}, #t70.{core::MapEntry::value});
     }
   } =>#t68, block {
     final core::Set<core::int> #t71 = col::LinkedHashSet::•<core::int>();
@@ -378,7 +378,7 @@
       if(!#t72.{core::Object::==}(null))
         for (final dynamic #t73 in #t72{core::Iterable<dynamic>}) {
           final core::int #t74 = #t73 as{TypeError,ForNonNullableByDefault} core::int;
-          #t71.{core::Set::add}(#t74);
+          #t71.{core::Set::add}{Invariant}(#t74);
         }
     }
   } =>#t71, block {
@@ -388,7 +388,7 @@
       if(!#t76.{core::Object::==}(null))
         for (final dynamic #t77 in #t76{core::Iterable<dynamic>}) {
           final core::int #t78 = #t77 as{TypeError,ForNonNullableByDefault} core::int;
-          #t75.{core::Set::add}(#t78);
+          #t75.{core::Set::add}{Invariant}(#t78);
         }
     }
   } =>#t75, block {
@@ -398,7 +398,7 @@
       if(!#t80.{core::Object::==}(null))
         for (final dynamic #t81 in #t80{core::Iterable<dynamic>}) {
           final core::int #t82 = #t81 as{TypeError,ForNonNullableByDefault} core::int;
-          #t79.{core::Set::add}(#t82);
+          #t79.{core::Set::add}{Invariant}(#t82);
         }
     }
   } =>#t79, block {
@@ -407,7 +407,7 @@
       final core::Map<core::int, core::int>? #t84 = d;
       if(!#t84.{core::Object::==}(null))
         for (final core::MapEntry<core::int, core::int> #t85 in #t84{core::Map<core::int, core::int>}.{core::Map::entries})
-          #t83.{core::Map::[]=}(#t85.{core::MapEntry::key}, #t85.{core::MapEntry::value});
+          #t83.{core::Map::[]=}{Invariant}(#t85.{core::MapEntry::key}, #t85.{core::MapEntry::value});
     }
   } =>#t83, block {
     final core::Set<core::int> #t86 = col::LinkedHashSet::•<core::int>();
@@ -416,7 +416,7 @@
       if(!#t87.{core::Object::==}(null))
         for (final dynamic #t88 in #t87{core::Iterable<dynamic>}) {
           final core::int #t89 = #t88 as{TypeError,ForNonNullableByDefault} core::int;
-          #t86.{core::Set::add}(#t89);
+          #t86.{core::Set::add}{Invariant}(#t89);
         }
     }
   } =>#t86, block {
@@ -426,7 +426,7 @@
       if(!#t91.{core::Object::==}(null))
         for (final dynamic #t92 in #t91{core::Iterable<dynamic>}) {
           final core::int #t93 = #t92 as{TypeError,ForNonNullableByDefault} core::int;
-          #t90.{core::Set::add}(#t93);
+          #t90.{core::Set::add}{Invariant}(#t93);
         }
     }
   } =>#t90, block {
@@ -436,7 +436,7 @@
       if(!#t95.{core::Object::==}(null))
         for (final dynamic #t96 in #t95{core::Iterable<dynamic>}) {
           final core::int #t97 = #t96 as{TypeError,ForNonNullableByDefault} core::int;
-          #t94.{core::Set::add}(#t97);
+          #t94.{core::Set::add}{Invariant}(#t97);
         }
     }
   } =>#t94, block {
@@ -445,7 +445,7 @@
       final core::Map<core::int, core::int>? #t99 = d;
       if(!#t99.{core::Object::==}(null))
         for (final core::MapEntry<core::int, core::int> #t100 in #t99{core::Map<core::int, core::int>}.{core::Map::entries})
-          #t98.{core::Map::[]=}(#t100.{core::MapEntry::key}, #t100.{core::MapEntry::value});
+          #t98.{core::Map::[]=}{Invariant}(#t100.{core::MapEntry::key}, #t100.{core::MapEntry::value});
     }
   } =>#t98];
 }
@@ -456,7 +456,7 @@
     {...x}, // Error.
         ^") {
       final core::int #t103 = #t102 as{TypeError,ForNonNullableByDefault} core::int;
-      #t101.{core::Set::add}(#t103);
+      #t101.{core::Set::add}{Invariant}(#t103);
     }
   } =>#t101, block {
     final core::Set<core::int> #t104 = col::LinkedHashSet::•<core::int>();
@@ -464,7 +464,7 @@
     {...y}, // Error.
         ^") {
       final core::int #t106 = #t105 as{TypeError,ForNonNullableByDefault} core::int;
-      #t104.{core::Set::add}(#t106);
+      #t104.{core::Set::add}{Invariant}(#t106);
     }
   } =>#t104, block {
     final core::Set<core::int> #t107 = col::LinkedHashSet::•<core::int>();
@@ -472,7 +472,7 @@
     {...z}, // Error.
         ^") {
       final core::int #t109 = #t108 as{TypeError,ForNonNullableByDefault} core::int;
-      #t107.{core::Set::add}(#t109);
+      #t107.{core::Set::add}{Invariant}(#t109);
     }
   } =>#t107, <core::int, core::int>{invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:53:9: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {...w}, // Error.
@@ -480,7 +480,7 @@
     <int, int>{...x}, // Error.
                   ^": null}, block {
     final core::Set<core::int> #t110 = col::LinkedHashSet::•<core::int>();
-    #t110.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:55:14: Error: Unexpected type 'W' of a spread.  Expected 'dynamic' or an Iterable.
+    #t110.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:55:14: Error: Unexpected type 'W' of a spread.  Expected 'dynamic' or an Iterable.
     <int>{...w}, // Error.
              ^");
   } =>#t110, block {
@@ -490,7 +490,7 @@
     {if (condition) ...x}, // Error.
                        ^") {
         final core::int #t113 = #t112 as{TypeError,ForNonNullableByDefault} core::int;
-        #t111.{core::Set::add}(#t113);
+        #t111.{core::Set::add}{Invariant}(#t113);
       }
   } =>#t111, block {
     final core::Set<core::int> #t114 = col::LinkedHashSet::•<core::int>();
@@ -499,7 +499,7 @@
     {if (condition) ...y}, // Error.
                        ^") {
         final core::int #t116 = #t115 as{TypeError,ForNonNullableByDefault} core::int;
-        #t114.{core::Set::add}(#t116);
+        #t114.{core::Set::add}{Invariant}(#t116);
       }
   } =>#t114, block {
     final core::Set<core::int> #t117 = col::LinkedHashSet::•<core::int>();
@@ -508,12 +508,12 @@
     {if (condition) ...z}, // Error.
                        ^") {
         final core::int #t119 = #t118 as{TypeError,ForNonNullableByDefault} core::int;
-        #t117.{core::Set::add}(#t119);
+        #t117.{core::Set::add}{Invariant}(#t119);
       }
   } =>#t117, block {
     final core::Map<core::int, core::int> #t120 = <core::int, core::int>{};
     if(condition)
-      #t120.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:59:24: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t120.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:59:24: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {if (condition) ...w}, // Error.
                        ^", null);
   } =>#t120, block {
@@ -523,7 +523,7 @@
     {for (dynamic e in iterable) ...x}, // Error.
                                     ^") {
         final core::int #t123 = #t122 as{TypeError,ForNonNullableByDefault} core::int;
-        #t121.{core::Set::add}(#t123);
+        #t121.{core::Set::add}{Invariant}(#t123);
       }
   } =>#t121, block {
     final core::Set<core::int> #t124 = col::LinkedHashSet::•<core::int>();
@@ -532,7 +532,7 @@
     {for (dynamic e in iterable) ...y}, // Error.
                                     ^") {
         final core::int #t126 = #t125 as{TypeError,ForNonNullableByDefault} core::int;
-        #t124.{core::Set::add}(#t126);
+        #t124.{core::Set::add}{Invariant}(#t126);
       }
   } =>#t124, block {
     final core::Set<core::int> #t127 = col::LinkedHashSet::•<core::int>();
@@ -541,12 +541,12 @@
     {for (dynamic e in iterable) ...z}, // Error.
                                     ^") {
         final core::int #t129 = #t128 as{TypeError,ForNonNullableByDefault} core::int;
-        #t127.{core::Set::add}(#t129);
+        #t127.{core::Set::add}{Invariant}(#t129);
       }
   } =>#t127, block {
     final core::Map<core::int, core::int> #t130 = <core::int, core::int>{};
     for (dynamic e in iterable)
-      #t130.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:63:37: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t130.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:63:37: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {for (dynamic e in iterable) ...w}, // Error.
                                     ^", null);
   } =>#t130, block {
@@ -556,7 +556,7 @@
     {for (int i = 0; i < 42; ++i) ...x}, // Error.
                                      ^") {
         final core::int #t133 = #t132 as{TypeError,ForNonNullableByDefault} core::int;
-        #t131.{core::Set::add}(#t133);
+        #t131.{core::Set::add}{Invariant}(#t133);
       }
   } =>#t131, block {
     final core::Set<core::int> #t134 = col::LinkedHashSet::•<core::int>();
@@ -565,7 +565,7 @@
     {for (int i = 0; i < 42; ++i) ...y}, // Error.
                                      ^") {
         final core::int #t136 = #t135 as{TypeError,ForNonNullableByDefault} core::int;
-        #t134.{core::Set::add}(#t136);
+        #t134.{core::Set::add}{Invariant}(#t136);
       }
   } =>#t134, block {
     final core::Set<core::int> #t137 = col::LinkedHashSet::•<core::int>();
@@ -574,12 +574,12 @@
     {for (int i = 0; i < 42; ++i) ...z}, // Error.
                                      ^") {
         final core::int #t139 = #t138 as{TypeError,ForNonNullableByDefault} core::int;
-        #t137.{core::Set::add}(#t139);
+        #t137.{core::Set::add}{Invariant}(#t139);
       }
   } =>#t137, block {
     final core::Map<core::int, core::int> #t140 = <core::int, core::int>{};
     for (core::int i = 0; i.{core::num::<}(42); i = i.{core::num::+}(1))
-      #t140.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:67:38: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t140.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:67:38: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {for (int i = 0; i < 42; ++i) ...w}, // Error.
                                      ^", null);
   } =>#t140, block {
@@ -588,7 +588,7 @@
     if(!#t142.{core::Object::==}(null))
       for (final dynamic #t143 in #t142{core::Iterable<dynamic>}) {
         final core::int #t144 = #t143 as{TypeError,ForNonNullableByDefault} core::int;
-        #t141.{core::Set::add}(#t144);
+        #t141.{core::Set::add}{Invariant}(#t144);
       }
   } =>#t141, block {
     final core::Set<core::int> #t145 = col::LinkedHashSet::•<core::int>();
@@ -596,7 +596,7 @@
     if(!#t146.{core::Object::==}(null))
       for (final dynamic #t147 in #t146{core::Iterable<dynamic>}) {
         final core::int #t148 = #t147 as{TypeError,ForNonNullableByDefault} core::int;
-        #t145.{core::Set::add}(#t148);
+        #t145.{core::Set::add}{Invariant}(#t148);
       }
   } =>#t145, block {
     final core::Set<core::int> #t149 = col::LinkedHashSet::•<core::int>();
@@ -604,14 +604,14 @@
     if(!#t150.{core::Object::==}(null))
       for (final dynamic #t151 in #t150{core::Iterable<dynamic>}) {
         final core::int #t152 = #t151 as{TypeError,ForNonNullableByDefault} core::int;
-        #t149.{core::Set::add}(#t152);
+        #t149.{core::Set::add}{Invariant}(#t152);
       }
   } =>#t149, block {
     final core::Map<core::int, core::int> #t153 = <core::int, core::int>{};
     final core::Map<core::int, core::int>? #t154 = w;
     if(!#t154.{core::Object::==}(null))
       for (final core::MapEntry<core::int, core::int> #t155 in #t154{core::Map<core::int, core::int>}.{core::Map::entries})
-        #t153.{core::Map::[]=}(#t155.{core::MapEntry::key}, #t155.{core::MapEntry::value});
+        #t153.{core::Map::[]=}{Invariant}(#t155.{core::MapEntry::key}, #t155.{core::MapEntry::value});
   } =>#t153, block {
     final core::Set<core::int> #t156 = col::LinkedHashSet::•<core::int>();
     if(condition) {
@@ -619,7 +619,7 @@
       if(!#t157.{core::Object::==}(null))
         for (final dynamic #t158 in #t157{core::Iterable<dynamic>}) {
           final core::int #t159 = #t158 as{TypeError,ForNonNullableByDefault} core::int;
-          #t156.{core::Set::add}(#t159);
+          #t156.{core::Set::add}{Invariant}(#t159);
         }
     }
   } =>#t156, block {
@@ -629,7 +629,7 @@
       if(!#t161.{core::Object::==}(null))
         for (final dynamic #t162 in #t161{core::Iterable<dynamic>}) {
           final core::int #t163 = #t162 as{TypeError,ForNonNullableByDefault} core::int;
-          #t160.{core::Set::add}(#t163);
+          #t160.{core::Set::add}{Invariant}(#t163);
         }
     }
   } =>#t160, block {
@@ -639,7 +639,7 @@
       if(!#t165.{core::Object::==}(null))
         for (final dynamic #t166 in #t165{core::Iterable<dynamic>}) {
           final core::int #t167 = #t166 as{TypeError,ForNonNullableByDefault} core::int;
-          #t164.{core::Set::add}(#t167);
+          #t164.{core::Set::add}{Invariant}(#t167);
         }
     }
   } =>#t164, block {
@@ -648,7 +648,7 @@
       final core::Map<core::int, core::int>? #t169 = w;
       if(!#t169.{core::Object::==}(null))
         for (final core::MapEntry<core::int, core::int> #t170 in #t169{core::Map<core::int, core::int>}.{core::Map::entries})
-          #t168.{core::Map::[]=}(#t170.{core::MapEntry::key}, #t170.{core::MapEntry::value});
+          #t168.{core::Map::[]=}{Invariant}(#t170.{core::MapEntry::key}, #t170.{core::MapEntry::value});
     }
   } =>#t168, block {
     final core::Set<core::int> #t171 = col::LinkedHashSet::•<core::int>();
@@ -657,7 +657,7 @@
       if(!#t172.{core::Object::==}(null))
         for (final dynamic #t173 in #t172{core::Iterable<dynamic>}) {
           final core::int #t174 = #t173 as{TypeError,ForNonNullableByDefault} core::int;
-          #t171.{core::Set::add}(#t174);
+          #t171.{core::Set::add}{Invariant}(#t174);
         }
     }
   } =>#t171, block {
@@ -667,7 +667,7 @@
       if(!#t176.{core::Object::==}(null))
         for (final dynamic #t177 in #t176{core::Iterable<dynamic>}) {
           final core::int #t178 = #t177 as{TypeError,ForNonNullableByDefault} core::int;
-          #t175.{core::Set::add}(#t178);
+          #t175.{core::Set::add}{Invariant}(#t178);
         }
     }
   } =>#t175, block {
@@ -677,7 +677,7 @@
       if(!#t180.{core::Object::==}(null))
         for (final dynamic #t181 in #t180{core::Iterable<dynamic>}) {
           final core::int #t182 = #t181 as{TypeError,ForNonNullableByDefault} core::int;
-          #t179.{core::Set::add}(#t182);
+          #t179.{core::Set::add}{Invariant}(#t182);
         }
     }
   } =>#t179, block {
@@ -686,7 +686,7 @@
       final core::Map<core::int, core::int>? #t184 = w;
       if(!#t184.{core::Object::==}(null))
         for (final core::MapEntry<core::int, core::int> #t185 in #t184{core::Map<core::int, core::int>}.{core::Map::entries})
-          #t183.{core::Map::[]=}(#t185.{core::MapEntry::key}, #t185.{core::MapEntry::value});
+          #t183.{core::Map::[]=}{Invariant}(#t185.{core::MapEntry::key}, #t185.{core::MapEntry::value});
     }
   } =>#t183, block {
     final core::Set<core::int> #t186 = col::LinkedHashSet::•<core::int>();
@@ -695,7 +695,7 @@
       if(!#t187.{core::Object::==}(null))
         for (final dynamic #t188 in #t187{core::Iterable<dynamic>}) {
           final core::int #t189 = #t188 as{TypeError,ForNonNullableByDefault} core::int;
-          #t186.{core::Set::add}(#t189);
+          #t186.{core::Set::add}{Invariant}(#t189);
         }
     }
   } =>#t186, block {
@@ -705,7 +705,7 @@
       if(!#t191.{core::Object::==}(null))
         for (final dynamic #t192 in #t191{core::Iterable<dynamic>}) {
           final core::int #t193 = #t192 as{TypeError,ForNonNullableByDefault} core::int;
-          #t190.{core::Set::add}(#t193);
+          #t190.{core::Set::add}{Invariant}(#t193);
         }
     }
   } =>#t190, block {
@@ -715,7 +715,7 @@
       if(!#t195.{core::Object::==}(null))
         for (final dynamic #t196 in #t195{core::Iterable<dynamic>}) {
           final core::int #t197 = #t196 as{TypeError,ForNonNullableByDefault} core::int;
-          #t194.{core::Set::add}(#t197);
+          #t194.{core::Set::add}{Invariant}(#t197);
         }
     }
   } =>#t194, block {
@@ -724,7 +724,7 @@
       final core::Map<core::int, core::int>? #t199 = w;
       if(!#t199.{core::Object::==}(null))
         for (final core::MapEntry<core::int, core::int> #t200 in #t199{core::Map<core::int, core::int>}.{core::Map::entries})
-          #t198.{core::Map::[]=}(#t200.{core::MapEntry::key}, #t200.{core::MapEntry::value});
+          #t198.{core::Map::[]=}{Invariant}(#t200.{core::MapEntry::key}, #t200.{core::MapEntry::value});
     }
   } =>#t198];
 }
diff --git a/pkg/front_end/testcases/nnbd/issue43495.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd/issue43495.dart.weak.transformed.expect
index 2c74f65..e3ffc57 100644
--- a/pkg/front_end/testcases/nnbd/issue43495.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/nnbd/issue43495.dart.weak.transformed.expect
@@ -175,7 +175,7 @@
     {...a}, // Error.
         ^") {
       final core::int #t3 = #t2 as{TypeError,ForNonNullableByDefault} core::int;
-      #t1.{core::Set::add}(#t3);
+      #t1.{core::Set::add}{Invariant}(#t3);
     }
   } =>#t1, block {
     final core::Set<core::int> #t4 = new col::_CompactLinkedHashSet::•<core::int>();
@@ -183,7 +183,7 @@
     {...b}, // Error.
         ^") {
       final core::int #t6 = #t5 as{TypeError,ForNonNullableByDefault} core::int;
-      #t4.{core::Set::add}(#t6);
+      #t4.{core::Set::add}{Invariant}(#t6);
     }
   } =>#t4, block {
     final core::Set<core::int> #t7 = new col::_CompactLinkedHashSet::•<core::int>();
@@ -191,7 +191,7 @@
     {...c}, // Error.
         ^") {
       final core::int #t9 = #t8 as{TypeError,ForNonNullableByDefault} core::int;
-      #t7.{core::Set::add}(#t9);
+      #t7.{core::Set::add}{Invariant}(#t9);
     }
   } =>#t7, <core::int, core::int>{invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:11:9: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {...d}, // Error.
@@ -200,7 +200,7 @@
     <int, int>{...a}, // Error.
                   ^": null}, block {
     final core::Set<core::int> #t10 = new col::_CompactLinkedHashSet::•<core::int>();
-    #t10.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:13:14: Error: Unexpected type 'Map<int, int>?' of a spread.  Expected 'dynamic' or an Iterable.
+    #t10.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:13:14: Error: Unexpected type 'Map<int, int>?' of a spread.  Expected 'dynamic' or an Iterable.
  - 'Map' is from 'dart:core'.
     <int>{...d}, // Error.
              ^");
@@ -211,7 +211,7 @@
     {if (condition) ...a}, // Error.
                        ^") {
         final core::int #t13 = #t12 as{TypeError,ForNonNullableByDefault} core::int;
-        #t11.{core::Set::add}(#t13);
+        #t11.{core::Set::add}{Invariant}(#t13);
       }
   } =>#t11, block {
     final core::Set<core::int> #t14 = new col::_CompactLinkedHashSet::•<core::int>();
@@ -220,7 +220,7 @@
     {if (condition) ...b}, // Error.
                        ^") {
         final core::int #t16 = #t15 as{TypeError,ForNonNullableByDefault} core::int;
-        #t14.{core::Set::add}(#t16);
+        #t14.{core::Set::add}{Invariant}(#t16);
       }
   } =>#t14, block {
     final core::Set<core::int> #t17 = new col::_CompactLinkedHashSet::•<core::int>();
@@ -229,12 +229,12 @@
     {if (condition) ...c}, // Error.
                        ^") {
         final core::int #t19 = #t18 as{TypeError,ForNonNullableByDefault} core::int;
-        #t17.{core::Set::add}(#t19);
+        #t17.{core::Set::add}{Invariant}(#t19);
       }
   } =>#t17, block {
     final core::Map<core::int, core::int> #t20 = <core::int, core::int>{};
     if(condition)
-      #t20.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:17:24: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t20.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:17:24: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {if (condition) ...d}, // Error.
                        ^", null);
   } =>#t20, block {
@@ -247,7 +247,7 @@
     {for (dynamic e in iterable) ...a}, // Error.
                                     ^") {
           final core::int #t23 = #t22 as{TypeError,ForNonNullableByDefault} core::int;
-          #t21.{core::Set::add}(#t23);
+          #t21.{core::Set::add}{Invariant}(#t23);
         }
       }
     }
@@ -261,7 +261,7 @@
     {for (dynamic e in iterable) ...b}, // Error.
                                     ^") {
           final core::int #t26 = #t25 as{TypeError,ForNonNullableByDefault} core::int;
-          #t24.{core::Set::add}(#t26);
+          #t24.{core::Set::add}{Invariant}(#t26);
         }
       }
     }
@@ -275,7 +275,7 @@
     {for (dynamic e in iterable) ...c}, // Error.
                                     ^") {
           final core::int #t29 = #t28 as{TypeError,ForNonNullableByDefault} core::int;
-          #t27.{core::Set::add}(#t29);
+          #t27.{core::Set::add}{Invariant}(#t29);
         }
       }
     }
@@ -285,7 +285,7 @@
       core::Iterator<dynamic> :sync-for-iterator = iterable.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         dynamic e = :sync-for-iterator.{core::Iterator::current};
-        #t30.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:21:37: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+        #t30.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:21:37: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {for (dynamic e in iterable) ...d}, // Error.
                                     ^", null);
       }
@@ -297,7 +297,7 @@
     {for (int i = 0; i < 42; ++i) ...a}, // Error.
                                      ^") {
         final core::int #t33 = #t32 as{TypeError,ForNonNullableByDefault} core::int;
-        #t31.{core::Set::add}(#t33);
+        #t31.{core::Set::add}{Invariant}(#t33);
       }
   } =>#t31, block {
     final core::Set<core::int> #t34 = new col::_CompactLinkedHashSet::•<core::int>();
@@ -306,7 +306,7 @@
     {for (int i = 0; i < 42; ++i) ...b}, // Error.
                                      ^") {
         final core::int #t36 = #t35 as{TypeError,ForNonNullableByDefault} core::int;
-        #t34.{core::Set::add}(#t36);
+        #t34.{core::Set::add}{Invariant}(#t36);
       }
   } =>#t34, block {
     final core::Set<core::int> #t37 = new col::_CompactLinkedHashSet::•<core::int>();
@@ -315,12 +315,12 @@
     {for (int i = 0; i < 42; ++i) ...c}, // Error.
                                      ^") {
         final core::int #t39 = #t38 as{TypeError,ForNonNullableByDefault} core::int;
-        #t37.{core::Set::add}(#t39);
+        #t37.{core::Set::add}{Invariant}(#t39);
       }
   } =>#t37, block {
     final core::Map<core::int, core::int> #t40 = <core::int, core::int>{};
     for (core::int i = 0; i.{core::num::<}(42); i = i.{core::num::+}(1))
-      #t40.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:25:38: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t40.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:25:38: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {for (int i = 0; i < 42; ++i) ...d}, // Error.
                                      ^", null);
   } =>#t40, block {
@@ -332,7 +332,7 @@
         final dynamic #t43 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int #t44 = #t43 as{TypeError,ForNonNullableByDefault} core::int;
-          #t41.{core::Set::add}(#t44);
+          #t41.{core::Set::add}{Invariant}(#t44);
         }
       }
     }
@@ -345,7 +345,7 @@
         final dynamic #t47 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int #t48 = #t47 as{TypeError,ForNonNullableByDefault} core::int;
-          #t45.{core::Set::add}(#t48);
+          #t45.{core::Set::add}{Invariant}(#t48);
         }
       }
     }
@@ -358,7 +358,7 @@
         final dynamic #t51 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int #t52 = #t51 as{TypeError,ForNonNullableByDefault} core::int;
-          #t49.{core::Set::add}(#t52);
+          #t49.{core::Set::add}{Invariant}(#t52);
         }
       }
     }
@@ -369,7 +369,7 @@
       core::Iterator<core::MapEntry<core::int, core::int>> :sync-for-iterator = #t54{core::Map<core::int, core::int>}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::int, core::int> #t55 = :sync-for-iterator.{core::Iterator::current};
-        #t53.{core::Map::[]=}(#t55.{core::MapEntry::key}, #t55.{core::MapEntry::value});
+        #t53.{core::Map::[]=}{Invariant}(#t55.{core::MapEntry::key}, #t55.{core::MapEntry::value});
       }
     }
   } =>#t53, block {
@@ -382,7 +382,7 @@
           final dynamic #t58 = :sync-for-iterator.{core::Iterator::current};
           {
             final core::int #t59 = #t58 as{TypeError,ForNonNullableByDefault} core::int;
-            #t56.{core::Set::add}(#t59);
+            #t56.{core::Set::add}{Invariant}(#t59);
           }
         }
       }
@@ -397,7 +397,7 @@
           final dynamic #t62 = :sync-for-iterator.{core::Iterator::current};
           {
             final core::int #t63 = #t62 as{TypeError,ForNonNullableByDefault} core::int;
-            #t60.{core::Set::add}(#t63);
+            #t60.{core::Set::add}{Invariant}(#t63);
           }
         }
       }
@@ -412,7 +412,7 @@
           final dynamic #t66 = :sync-for-iterator.{core::Iterator::current};
           {
             final core::int #t67 = #t66 as{TypeError,ForNonNullableByDefault} core::int;
-            #t64.{core::Set::add}(#t67);
+            #t64.{core::Set::add}{Invariant}(#t67);
           }
         }
       }
@@ -425,7 +425,7 @@
         core::Iterator<core::MapEntry<core::int, core::int>> :sync-for-iterator = #t69{core::Map<core::int, core::int>}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::int, core::int> #t70 = :sync-for-iterator.{core::Iterator::current};
-          #t68.{core::Map::[]=}(#t70.{core::MapEntry::key}, #t70.{core::MapEntry::value});
+          #t68.{core::Map::[]=}{Invariant}(#t70.{core::MapEntry::key}, #t70.{core::MapEntry::value});
         }
       }
     }
@@ -443,7 +443,7 @@
               final dynamic #t73 = :sync-for-iterator.{core::Iterator::current};
               {
                 final core::int #t74 = #t73 as{TypeError,ForNonNullableByDefault} core::int;
-                #t71.{core::Set::add}(#t74);
+                #t71.{core::Set::add}{Invariant}(#t74);
               }
             }
           }
@@ -464,7 +464,7 @@
               final dynamic #t77 = :sync-for-iterator.{core::Iterator::current};
               {
                 final core::int #t78 = #t77 as{TypeError,ForNonNullableByDefault} core::int;
-                #t75.{core::Set::add}(#t78);
+                #t75.{core::Set::add}{Invariant}(#t78);
               }
             }
           }
@@ -485,7 +485,7 @@
               final dynamic #t81 = :sync-for-iterator.{core::Iterator::current};
               {
                 final core::int #t82 = #t81 as{TypeError,ForNonNullableByDefault} core::int;
-                #t79.{core::Set::add}(#t82);
+                #t79.{core::Set::add}{Invariant}(#t82);
               }
             }
           }
@@ -504,7 +504,7 @@
             core::Iterator<core::MapEntry<core::int, core::int>> :sync-for-iterator = #t84{core::Map<core::int, core::int>}.{core::Map::entries}.{core::Iterable::iterator};
             for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
               final core::MapEntry<core::int, core::int> #t85 = :sync-for-iterator.{core::Iterator::current};
-              #t83.{core::Map::[]=}(#t85.{core::MapEntry::key}, #t85.{core::MapEntry::value});
+              #t83.{core::Map::[]=}{Invariant}(#t85.{core::MapEntry::key}, #t85.{core::MapEntry::value});
             }
           }
         }
@@ -520,7 +520,7 @@
           final dynamic #t88 = :sync-for-iterator.{core::Iterator::current};
           {
             final core::int #t89 = #t88 as{TypeError,ForNonNullableByDefault} core::int;
-            #t86.{core::Set::add}(#t89);
+            #t86.{core::Set::add}{Invariant}(#t89);
           }
         }
       }
@@ -535,7 +535,7 @@
           final dynamic #t92 = :sync-for-iterator.{core::Iterator::current};
           {
             final core::int #t93 = #t92 as{TypeError,ForNonNullableByDefault} core::int;
-            #t90.{core::Set::add}(#t93);
+            #t90.{core::Set::add}{Invariant}(#t93);
           }
         }
       }
@@ -550,7 +550,7 @@
           final dynamic #t96 = :sync-for-iterator.{core::Iterator::current};
           {
             final core::int #t97 = #t96 as{TypeError,ForNonNullableByDefault} core::int;
-            #t94.{core::Set::add}(#t97);
+            #t94.{core::Set::add}{Invariant}(#t97);
           }
         }
       }
@@ -563,7 +563,7 @@
         core::Iterator<core::MapEntry<core::int, core::int>> :sync-for-iterator = #t99{core::Map<core::int, core::int>}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::int, core::int> #t100 = :sync-for-iterator.{core::Iterator::current};
-          #t98.{core::Map::[]=}(#t100.{core::MapEntry::key}, #t100.{core::MapEntry::value});
+          #t98.{core::Map::[]=}{Invariant}(#t100.{core::MapEntry::key}, #t100.{core::MapEntry::value});
         }
       }
     }
@@ -576,7 +576,7 @@
     {...x}, // Error.
         ^") {
       final core::int #t103 = #t102 as{TypeError,ForNonNullableByDefault} core::int;
-      #t101.{core::Set::add}(#t103);
+      #t101.{core::Set::add}{Invariant}(#t103);
     }
   } =>#t101, block {
     final core::Set<core::int> #t104 = new col::_CompactLinkedHashSet::•<core::int>();
@@ -584,7 +584,7 @@
     {...y}, // Error.
         ^") {
       final core::int #t106 = #t105 as{TypeError,ForNonNullableByDefault} core::int;
-      #t104.{core::Set::add}(#t106);
+      #t104.{core::Set::add}{Invariant}(#t106);
     }
   } =>#t104, block {
     final core::Set<core::int> #t107 = new col::_CompactLinkedHashSet::•<core::int>();
@@ -592,7 +592,7 @@
     {...z}, // Error.
         ^") {
       final core::int #t109 = #t108 as{TypeError,ForNonNullableByDefault} core::int;
-      #t107.{core::Set::add}(#t109);
+      #t107.{core::Set::add}{Invariant}(#t109);
     }
   } =>#t107, <core::int, core::int>{invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:53:9: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {...w}, // Error.
@@ -600,7 +600,7 @@
     <int, int>{...x}, // Error.
                   ^": null}, block {
     final core::Set<core::int> #t110 = new col::_CompactLinkedHashSet::•<core::int>();
-    #t110.{core::Set::add}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:55:14: Error: Unexpected type 'W' of a spread.  Expected 'dynamic' or an Iterable.
+    #t110.{core::Set::add}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:55:14: Error: Unexpected type 'W' of a spread.  Expected 'dynamic' or an Iterable.
     <int>{...w}, // Error.
              ^");
   } =>#t110, block {
@@ -610,7 +610,7 @@
     {if (condition) ...x}, // Error.
                        ^") {
         final core::int #t113 = #t112 as{TypeError,ForNonNullableByDefault} core::int;
-        #t111.{core::Set::add}(#t113);
+        #t111.{core::Set::add}{Invariant}(#t113);
       }
   } =>#t111, block {
     final core::Set<core::int> #t114 = new col::_CompactLinkedHashSet::•<core::int>();
@@ -619,7 +619,7 @@
     {if (condition) ...y}, // Error.
                        ^") {
         final core::int #t116 = #t115 as{TypeError,ForNonNullableByDefault} core::int;
-        #t114.{core::Set::add}(#t116);
+        #t114.{core::Set::add}{Invariant}(#t116);
       }
   } =>#t114, block {
     final core::Set<core::int> #t117 = new col::_CompactLinkedHashSet::•<core::int>();
@@ -628,12 +628,12 @@
     {if (condition) ...z}, // Error.
                        ^") {
         final core::int #t119 = #t118 as{TypeError,ForNonNullableByDefault} core::int;
-        #t117.{core::Set::add}(#t119);
+        #t117.{core::Set::add}{Invariant}(#t119);
       }
   } =>#t117, block {
     final core::Map<core::int, core::int> #t120 = <core::int, core::int>{};
     if(condition)
-      #t120.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:59:24: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t120.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:59:24: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {if (condition) ...w}, // Error.
                        ^", null);
   } =>#t120, block {
@@ -646,7 +646,7 @@
     {for (dynamic e in iterable) ...x}, // Error.
                                     ^") {
           final core::int #t123 = #t122 as{TypeError,ForNonNullableByDefault} core::int;
-          #t121.{core::Set::add}(#t123);
+          #t121.{core::Set::add}{Invariant}(#t123);
         }
       }
     }
@@ -660,7 +660,7 @@
     {for (dynamic e in iterable) ...y}, // Error.
                                     ^") {
           final core::int #t126 = #t125 as{TypeError,ForNonNullableByDefault} core::int;
-          #t124.{core::Set::add}(#t126);
+          #t124.{core::Set::add}{Invariant}(#t126);
         }
       }
     }
@@ -674,7 +674,7 @@
     {for (dynamic e in iterable) ...z}, // Error.
                                     ^") {
           final core::int #t129 = #t128 as{TypeError,ForNonNullableByDefault} core::int;
-          #t127.{core::Set::add}(#t129);
+          #t127.{core::Set::add}{Invariant}(#t129);
         }
       }
     }
@@ -684,7 +684,7 @@
       core::Iterator<dynamic> :sync-for-iterator = iterable.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         dynamic e = :sync-for-iterator.{core::Iterator::current};
-        #t130.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:63:37: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+        #t130.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:63:37: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {for (dynamic e in iterable) ...w}, // Error.
                                     ^", null);
       }
@@ -696,7 +696,7 @@
     {for (int i = 0; i < 42; ++i) ...x}, // Error.
                                      ^") {
         final core::int #t133 = #t132 as{TypeError,ForNonNullableByDefault} core::int;
-        #t131.{core::Set::add}(#t133);
+        #t131.{core::Set::add}{Invariant}(#t133);
       }
   } =>#t131, block {
     final core::Set<core::int> #t134 = new col::_CompactLinkedHashSet::•<core::int>();
@@ -705,7 +705,7 @@
     {for (int i = 0; i < 42; ++i) ...y}, // Error.
                                      ^") {
         final core::int #t136 = #t135 as{TypeError,ForNonNullableByDefault} core::int;
-        #t134.{core::Set::add}(#t136);
+        #t134.{core::Set::add}{Invariant}(#t136);
       }
   } =>#t134, block {
     final core::Set<core::int> #t137 = new col::_CompactLinkedHashSet::•<core::int>();
@@ -714,12 +714,12 @@
     {for (int i = 0; i < 42; ++i) ...z}, // Error.
                                      ^") {
         final core::int #t139 = #t138 as{TypeError,ForNonNullableByDefault} core::int;
-        #t137.{core::Set::add}(#t139);
+        #t137.{core::Set::add}{Invariant}(#t139);
       }
   } =>#t137, block {
     final core::Map<core::int, core::int> #t140 = <core::int, core::int>{};
     for (core::int i = 0; i.{core::num::<}(42); i = i.{core::num::+}(1))
-      #t140.{core::Map::[]=}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:67:38: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
+      #t140.{core::Map::[]=}{Invariant}(invalid-expression "pkg/front_end/testcases/nnbd/issue43495.dart:67:38: Error: An expression whose value can be 'null' must be null-checked before it can be dereferenced.
     {for (int i = 0; i < 42; ++i) ...w}, // Error.
                                      ^", null);
   } =>#t140, block {
@@ -731,7 +731,7 @@
         final dynamic #t143 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int #t144 = #t143 as{TypeError,ForNonNullableByDefault} core::int;
-          #t141.{core::Set::add}(#t144);
+          #t141.{core::Set::add}{Invariant}(#t144);
         }
       }
     }
@@ -744,7 +744,7 @@
         final dynamic #t147 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int #t148 = #t147 as{TypeError,ForNonNullableByDefault} core::int;
-          #t145.{core::Set::add}(#t148);
+          #t145.{core::Set::add}{Invariant}(#t148);
         }
       }
     }
@@ -757,7 +757,7 @@
         final dynamic #t151 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int #t152 = #t151 as{TypeError,ForNonNullableByDefault} core::int;
-          #t149.{core::Set::add}(#t152);
+          #t149.{core::Set::add}{Invariant}(#t152);
         }
       }
     }
@@ -768,7 +768,7 @@
       core::Iterator<core::MapEntry<core::int, core::int>> :sync-for-iterator = #t154{core::Map<core::int, core::int>}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::int, core::int> #t155 = :sync-for-iterator.{core::Iterator::current};
-        #t153.{core::Map::[]=}(#t155.{core::MapEntry::key}, #t155.{core::MapEntry::value});
+        #t153.{core::Map::[]=}{Invariant}(#t155.{core::MapEntry::key}, #t155.{core::MapEntry::value});
       }
     }
   } =>#t153, block {
@@ -781,7 +781,7 @@
           final dynamic #t158 = :sync-for-iterator.{core::Iterator::current};
           {
             final core::int #t159 = #t158 as{TypeError,ForNonNullableByDefault} core::int;
-            #t156.{core::Set::add}(#t159);
+            #t156.{core::Set::add}{Invariant}(#t159);
           }
         }
       }
@@ -796,7 +796,7 @@
           final dynamic #t162 = :sync-for-iterator.{core::Iterator::current};
           {
             final core::int #t163 = #t162 as{TypeError,ForNonNullableByDefault} core::int;
-            #t160.{core::Set::add}(#t163);
+            #t160.{core::Set::add}{Invariant}(#t163);
           }
         }
       }
@@ -811,7 +811,7 @@
           final dynamic #t166 = :sync-for-iterator.{core::Iterator::current};
           {
             final core::int #t167 = #t166 as{TypeError,ForNonNullableByDefault} core::int;
-            #t164.{core::Set::add}(#t167);
+            #t164.{core::Set::add}{Invariant}(#t167);
           }
         }
       }
@@ -824,7 +824,7 @@
         core::Iterator<core::MapEntry<core::int, core::int>> :sync-for-iterator = #t169{core::Map<core::int, core::int>}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::int, core::int> #t170 = :sync-for-iterator.{core::Iterator::current};
-          #t168.{core::Map::[]=}(#t170.{core::MapEntry::key}, #t170.{core::MapEntry::value});
+          #t168.{core::Map::[]=}{Invariant}(#t170.{core::MapEntry::key}, #t170.{core::MapEntry::value});
         }
       }
     }
@@ -842,7 +842,7 @@
               final dynamic #t173 = :sync-for-iterator.{core::Iterator::current};
               {
                 final core::int #t174 = #t173 as{TypeError,ForNonNullableByDefault} core::int;
-                #t171.{core::Set::add}(#t174);
+                #t171.{core::Set::add}{Invariant}(#t174);
               }
             }
           }
@@ -863,7 +863,7 @@
               final dynamic #t177 = :sync-for-iterator.{core::Iterator::current};
               {
                 final core::int #t178 = #t177 as{TypeError,ForNonNullableByDefault} core::int;
-                #t175.{core::Set::add}(#t178);
+                #t175.{core::Set::add}{Invariant}(#t178);
               }
             }
           }
@@ -884,7 +884,7 @@
               final dynamic #t181 = :sync-for-iterator.{core::Iterator::current};
               {
                 final core::int #t182 = #t181 as{TypeError,ForNonNullableByDefault} core::int;
-                #t179.{core::Set::add}(#t182);
+                #t179.{core::Set::add}{Invariant}(#t182);
               }
             }
           }
@@ -903,7 +903,7 @@
             core::Iterator<core::MapEntry<core::int, core::int>> :sync-for-iterator = #t184{core::Map<core::int, core::int>}.{core::Map::entries}.{core::Iterable::iterator};
             for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
               final core::MapEntry<core::int, core::int> #t185 = :sync-for-iterator.{core::Iterator::current};
-              #t183.{core::Map::[]=}(#t185.{core::MapEntry::key}, #t185.{core::MapEntry::value});
+              #t183.{core::Map::[]=}{Invariant}(#t185.{core::MapEntry::key}, #t185.{core::MapEntry::value});
             }
           }
         }
@@ -919,7 +919,7 @@
           final dynamic #t188 = :sync-for-iterator.{core::Iterator::current};
           {
             final core::int #t189 = #t188 as{TypeError,ForNonNullableByDefault} core::int;
-            #t186.{core::Set::add}(#t189);
+            #t186.{core::Set::add}{Invariant}(#t189);
           }
         }
       }
@@ -934,7 +934,7 @@
           final dynamic #t192 = :sync-for-iterator.{core::Iterator::current};
           {
             final core::int #t193 = #t192 as{TypeError,ForNonNullableByDefault} core::int;
-            #t190.{core::Set::add}(#t193);
+            #t190.{core::Set::add}{Invariant}(#t193);
           }
         }
       }
@@ -949,7 +949,7 @@
           final dynamic #t196 = :sync-for-iterator.{core::Iterator::current};
           {
             final core::int #t197 = #t196 as{TypeError,ForNonNullableByDefault} core::int;
-            #t194.{core::Set::add}(#t197);
+            #t194.{core::Set::add}{Invariant}(#t197);
           }
         }
       }
@@ -962,7 +962,7 @@
         core::Iterator<core::MapEntry<core::int, core::int>> :sync-for-iterator = #t199{core::Map<core::int, core::int>}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<core::int, core::int> #t200 = :sync-for-iterator.{core::Iterator::current};
-          #t198.{core::Map::[]=}(#t200.{core::MapEntry::key}, #t200.{core::MapEntry::value});
+          #t198.{core::Map::[]=}{Invariant}(#t200.{core::MapEntry::key}, #t200.{core::MapEntry::value});
         }
       }
     }
diff --git a/pkg/front_end/testcases/nnbd/later.dart.strong.expect b/pkg/front_end/testcases/nnbd/later.dart.strong.expect
index 992c773..df47af6 100644
--- a/pkg/front_end/testcases/nnbd/later.dart.strong.expect
+++ b/pkg/front_end/testcases/nnbd/later.dart.strong.expect
@@ -113,7 +113,7 @@
   block {
     final core::List<core::int> #t1 = <core::int>[];
     for (core::int i = 0; i.{core::num::<}(10); i = i.{core::num::+}(1))
-      #t1.{core::List::add}(i);
+      #t1.{core::List::add}{Invariant}(i);
   } =>#t1;
 }
 static method hest() → dynamic async {
diff --git a/pkg/front_end/testcases/nnbd/later.dart.strong.transformed.expect b/pkg/front_end/testcases/nnbd/later.dart.strong.transformed.expect
index 597bd6c..25b17c9 100644
--- a/pkg/front_end/testcases/nnbd/later.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/nnbd/later.dart.strong.transformed.expect
@@ -120,7 +120,7 @@
   block {
     final core::List<core::int> #t1 = <core::int>[];
     for (core::int i = 0; i.{core::num::<}(10); i = i.{core::num::+}(1))
-      #t1.{core::List::add}(i);
+      #t1.{core::List::add}{Invariant}(i);
   } =>#t1;
 }
 static method hest() → dynamic /* originally async */ {
diff --git a/pkg/front_end/testcases/nnbd/later.dart.weak.expect b/pkg/front_end/testcases/nnbd/later.dart.weak.expect
index 992c773..df47af6 100644
--- a/pkg/front_end/testcases/nnbd/later.dart.weak.expect
+++ b/pkg/front_end/testcases/nnbd/later.dart.weak.expect
@@ -113,7 +113,7 @@
   block {
     final core::List<core::int> #t1 = <core::int>[];
     for (core::int i = 0; i.{core::num::<}(10); i = i.{core::num::+}(1))
-      #t1.{core::List::add}(i);
+      #t1.{core::List::add}{Invariant}(i);
   } =>#t1;
 }
 static method hest() → dynamic async {
diff --git a/pkg/front_end/testcases/nnbd/later.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd/later.dart.weak.transformed.expect
index 597bd6c..25b17c9 100644
--- a/pkg/front_end/testcases/nnbd/later.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/nnbd/later.dart.weak.transformed.expect
@@ -120,7 +120,7 @@
   block {
     final core::List<core::int> #t1 = <core::int>[];
     for (core::int i = 0; i.{core::num::<}(10); i = i.{core::num::+}(1))
-      #t1.{core::List::add}(i);
+      #t1.{core::List::add}{Invariant}(i);
   } =>#t1;
 }
 static method hest() → dynamic /* originally async */ {
diff --git a/pkg/front_end/testcases/nnbd/return_null.dart.strong.expect b/pkg/front_end/testcases/nnbd/return_null.dart.strong.expect
index 05a001d..ad7fa70 100644
--- a/pkg/front_end/testcases/nnbd/return_null.dart.strong.expect
+++ b/pkg/front_end/testcases/nnbd/return_null.dart.strong.expect
@@ -6,11 +6,11 @@
 // String returnImplicit() /*error*/ {
 //        ^
 //
-// pkg/front_end/testcases/nnbd/return_null.dart:13:10: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+// pkg/front_end/testcases/nnbd/return_null.dart:13:10: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
 //   return null; // error
 //          ^
 //
-// pkg/front_end/testcases/nnbd/return_null.dart:19:12: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+// pkg/front_end/testcases/nnbd/return_null.dart:19:12: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
 //     return null; // error
 //            ^
 //
@@ -31,11 +31,11 @@
 //   String returnImplicit() /* error */ {
 //   ^
 //
-// pkg/front_end/testcases/nnbd/return_null.dart:69:12: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+// pkg/front_end/testcases/nnbd/return_null.dart:69:12: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
 //     return null; // error
 //            ^
 //
-// pkg/front_end/testcases/nnbd/return_null.dart:75:14: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+// pkg/front_end/testcases/nnbd/return_null.dart:75:14: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
 //       return null; // error
 //              ^
 //
@@ -78,14 +78,14 @@
 }
 static method returnExplicit() → core::String {
   core::print("foo");
-  return let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:13:10: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+  return let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:13:10: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
   return null; // error
          ^" in null as{TypeError,ForNonNullableByDefault} core::String;
 }
 static method returnMixed(core::bool b) → core::String {
   if(b) {
     core::print("foo");
-    return let final<BottomType> #t3 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:19:12: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+    return let final<BottomType> #t3 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:19:12: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
     return null; // error
            ^" in null as{TypeError,ForNonNullableByDefault} core::String;
   }
@@ -147,14 +147,14 @@
   }
   function returnExplicit() → core::String {
     core::print("foo");
-    return let final<BottomType> #t8 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:69:12: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+    return let final<BottomType> #t8 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:69:12: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
     return null; // error
            ^" in null as{TypeError,ForNonNullableByDefault} core::String;
   }
   function returnMixed(core::bool b) → core::String {
     if(b) {
       core::print("foo");
-      return let final<BottomType> #t9 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:75:14: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+      return let final<BottomType> #t9 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:75:14: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
       return null; // error
              ^" in null as{TypeError,ForNonNullableByDefault} core::String;
     }
diff --git a/pkg/front_end/testcases/nnbd/return_null.dart.strong.transformed.expect b/pkg/front_end/testcases/nnbd/return_null.dart.strong.transformed.expect
index 08d3990..66eca58 100644
--- a/pkg/front_end/testcases/nnbd/return_null.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/nnbd/return_null.dart.strong.transformed.expect
@@ -6,11 +6,11 @@
 // String returnImplicit() /*error*/ {
 //        ^
 //
-// pkg/front_end/testcases/nnbd/return_null.dart:13:10: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+// pkg/front_end/testcases/nnbd/return_null.dart:13:10: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
 //   return null; // error
 //          ^
 //
-// pkg/front_end/testcases/nnbd/return_null.dart:19:12: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+// pkg/front_end/testcases/nnbd/return_null.dart:19:12: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
 //     return null; // error
 //            ^
 //
@@ -31,11 +31,11 @@
 //   String returnImplicit() /* error */ {
 //   ^
 //
-// pkg/front_end/testcases/nnbd/return_null.dart:69:12: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+// pkg/front_end/testcases/nnbd/return_null.dart:69:12: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
 //     return null; // error
 //            ^
 //
-// pkg/front_end/testcases/nnbd/return_null.dart:75:14: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+// pkg/front_end/testcases/nnbd/return_null.dart:75:14: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
 //       return null; // error
 //              ^
 //
@@ -78,14 +78,14 @@
 }
 static method returnExplicit() → core::String {
   core::print("foo");
-  return let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:13:10: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+  return let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:13:10: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
   return null; // error
          ^" in let Null #t3 = null in #t3.==(null) ?{core::String} #t3 as{TypeError,ForNonNullableByDefault} core::String : #t3{core::String};
 }
 static method returnMixed(core::bool b) → core::String {
   if(b) {
     core::print("foo");
-    return let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:19:12: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+    return let final<BottomType> #t4 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:19:12: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
     return null; // error
            ^" in let Null #t5 = null in #t5.==(null) ?{core::String} #t5 as{TypeError,ForNonNullableByDefault} core::String : #t5{core::String};
   }
@@ -362,14 +362,14 @@
   }
   function returnExplicit() → core::String {
     core::print("foo");
-    return let final<BottomType> #t10 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:69:12: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+    return let final<BottomType> #t10 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:69:12: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
     return null; // error
            ^" in let Null #t11 = null in #t11.==(null) ?{core::String} #t11 as{TypeError,ForNonNullableByDefault} core::String : #t11{core::String};
   }
   function returnMixed(core::bool b) → core::String {
     if(b) {
       core::print("foo");
-      return let final<BottomType> #t12 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:75:14: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+      return let final<BottomType> #t12 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:75:14: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
       return null; // error
              ^" in let Null #t13 = null in #t13.==(null) ?{core::String} #t13 as{TypeError,ForNonNullableByDefault} core::String : #t13{core::String};
     }
diff --git a/pkg/front_end/testcases/nnbd/return_null.dart.weak.expect b/pkg/front_end/testcases/nnbd/return_null.dart.weak.expect
index 75aa5e4..e747dfe 100644
--- a/pkg/front_end/testcases/nnbd/return_null.dart.weak.expect
+++ b/pkg/front_end/testcases/nnbd/return_null.dart.weak.expect
@@ -6,11 +6,11 @@
 // String returnImplicit() /*error*/ {
 //        ^
 //
-// pkg/front_end/testcases/nnbd/return_null.dart:13:10: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+// pkg/front_end/testcases/nnbd/return_null.dart:13:10: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
 //   return null; // error
 //          ^
 //
-// pkg/front_end/testcases/nnbd/return_null.dart:19:12: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+// pkg/front_end/testcases/nnbd/return_null.dart:19:12: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
 //     return null; // error
 //            ^
 //
@@ -31,11 +31,11 @@
 //   String returnImplicit() /* error */ {
 //   ^
 //
-// pkg/front_end/testcases/nnbd/return_null.dart:69:12: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+// pkg/front_end/testcases/nnbd/return_null.dart:69:12: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
 //     return null; // error
 //            ^
 //
-// pkg/front_end/testcases/nnbd/return_null.dart:75:14: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+// pkg/front_end/testcases/nnbd/return_null.dart:75:14: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
 //       return null; // error
 //              ^
 //
@@ -79,14 +79,14 @@
 }
 static method returnExplicit() → core::String {
   core::print("foo");
-  return let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:13:10: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+  return let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:13:10: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
   return null; // error
          ^" in null as{TypeError,ForNonNullableByDefault} core::String;
 }
 static method returnMixed(core::bool b) → core::String {
   if(b) {
     core::print("foo");
-    return let final<BottomType> #t3 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:19:12: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+    return let final<BottomType> #t3 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:19:12: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
     return null; // error
            ^" in null as{TypeError,ForNonNullableByDefault} core::String;
   }
@@ -151,14 +151,14 @@
   }
   function returnExplicit() → core::String {
     core::print("foo");
-    return let final<BottomType> #t8 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:69:12: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+    return let final<BottomType> #t8 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:69:12: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
     return null; // error
            ^" in null as{TypeError,ForNonNullableByDefault} core::String;
   }
   function returnMixed(core::bool b) → core::String {
     if(b) {
       core::print("foo");
-      return let final<BottomType> #t9 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:75:14: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+      return let final<BottomType> #t9 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:75:14: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
       return null; // error
              ^" in null as{TypeError,ForNonNullableByDefault} core::String;
     }
diff --git a/pkg/front_end/testcases/nnbd/return_null.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd/return_null.dart.weak.transformed.expect
index 39f41e3..4b3b79c 100644
--- a/pkg/front_end/testcases/nnbd/return_null.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/nnbd/return_null.dart.weak.transformed.expect
@@ -6,11 +6,11 @@
 // String returnImplicit() /*error*/ {
 //        ^
 //
-// pkg/front_end/testcases/nnbd/return_null.dart:13:10: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+// pkg/front_end/testcases/nnbd/return_null.dart:13:10: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
 //   return null; // error
 //          ^
 //
-// pkg/front_end/testcases/nnbd/return_null.dart:19:12: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+// pkg/front_end/testcases/nnbd/return_null.dart:19:12: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
 //     return null; // error
 //            ^
 //
@@ -31,11 +31,11 @@
 //   String returnImplicit() /* error */ {
 //   ^
 //
-// pkg/front_end/testcases/nnbd/return_null.dart:69:12: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+// pkg/front_end/testcases/nnbd/return_null.dart:69:12: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
 //     return null; // error
 //            ^
 //
-// pkg/front_end/testcases/nnbd/return_null.dart:75:14: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+// pkg/front_end/testcases/nnbd/return_null.dart:75:14: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
 //       return null; // error
 //              ^
 //
@@ -79,14 +79,14 @@
 }
 static method returnExplicit() → core::String {
   core::print("foo");
-  return let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:13:10: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+  return let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:13:10: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
   return null; // error
          ^" in null;
 }
 static method returnMixed(core::bool b) → core::String {
   if(b) {
     core::print("foo");
-    return let final<BottomType> #t3 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:19:12: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+    return let final<BottomType> #t3 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:19:12: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
     return null; // error
            ^" in null;
   }
@@ -366,14 +366,14 @@
   }
   function returnExplicit() → core::String {
     core::print("foo");
-    return let final<BottomType> #t8 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:69:12: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+    return let final<BottomType> #t8 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:69:12: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
     return null; // error
            ^" in null;
   }
   function returnMixed(core::bool b) → core::String {
     if(b) {
       core::print("foo");
-      return let final<BottomType> #t9 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:75:14: Error: A value of type 'Null' can't be returned from a function with return type 'String' because 'Null' is nullable and 'String' isn't.
+      return let final<BottomType> #t9 = invalid-expression "pkg/front_end/testcases/nnbd/return_null.dart:75:14: Error: The value 'null' can't be returned from a function with return type 'String' because 'String' is not nullable.
       return null; // error
              ^" in null;
     }
diff --git a/pkg/front_end/testcases/nnbd/spread_if_null.dart.strong.expect b/pkg/front_end/testcases/nnbd/spread_if_null.dart.strong.expect
index 04612a2..ffceca9 100644
--- a/pkg/front_end/testcases/nnbd/spread_if_null.dart.strong.expect
+++ b/pkg/front_end/testcases/nnbd/spread_if_null.dart.strong.expect
@@ -7,78 +7,78 @@
   core::List<core::int>? list = null;
   core::print( block {
     final core::List<core::int> #t1 = <core::int>[];
-    #t1.{core::List::add}(1);
-    #t1.{core::List::add}(2);
+    #t1.{core::List::add}{Invariant}(1);
+    #t1.{core::List::add}{Invariant}(2);
     final core::Iterable<core::int>? #t2 = list;
     if(!#t2.{core::Object::==}(null))
       for (final core::int #t3 in #t2{core::Iterable<core::int>})
-        #t1.{core::List::add}(#t3);
-    #t1.{core::List::add}(3);
+        #t1.{core::List::add}{Invariant}(#t3);
+    #t1.{core::List::add}{Invariant}(3);
   } =>#t1);
   core::print( block {
     final core::List<core::int> #t4 = <core::int>[];
-    #t4.{core::List::add}(1);
-    #t4.{core::List::add}(2);
+    #t4.{core::List::add}{Invariant}(1);
+    #t4.{core::List::add}{Invariant}(2);
     final core::Iterable<core::int>? #t5 = null;
     if(!#t5.{core::Object::==}(null))
       for (final core::int #t6 in #t5{core::Iterable<core::int>})
-        #t4.{core::List::add}(#t6);
-    #t4.{core::List::add}(3);
+        #t4.{core::List::add}{Invariant}(#t6);
+    #t4.{core::List::add}{Invariant}(3);
   } =>#t4);
   core::List<core::int> list1 = block {
     final core::List<core::int> #t7 = <core::int>[];
     final core::Iterable<core::int>? #t8 = list;
     if(!#t8.{core::Object::==}(null))
       for (final core::int #t9 in #t8{core::Iterable<core::int>})
-        #t7.{core::List::add}(#t9);
+        #t7.{core::List::add}{Invariant}(#t9);
   } =>#t7;
   core::List<Never> list2 = block {
     final core::List<Never> #t10 = <Never>[];
     final core::Iterable<Never>? #t11 = null;
     if(!#t11.{core::Object::==}(null))
       for (final Never #t12 in #t11{core::Iterable<Never>})
-        #t10.{core::List::add}(#t12);
+        #t10.{core::List::add}{Invariant}(#t12);
   } =>#t10;
   core::List<core::int> list3 = block {
     final core::List<core::int> #t13 = <core::int>[];
-    #t13.{core::List::add}(1);
-    #t13.{core::List::add}(2);
+    #t13.{core::List::add}{Invariant}(1);
+    #t13.{core::List::add}{Invariant}(2);
     final core::Iterable<core::int>? #t14 = list;
     if(!#t14.{core::Object::==}(null))
       for (final core::int #t15 in #t14{core::Iterable<core::int>})
-        #t13.{core::List::add}(#t15);
-    #t13.{core::List::add}(3);
+        #t13.{core::List::add}{Invariant}(#t15);
+    #t13.{core::List::add}{Invariant}(3);
   } =>#t13;
   core::List<core::int> list4 = block {
     final core::List<core::int> #t16 = <core::int>[];
-    #t16.{core::List::add}(1);
-    #t16.{core::List::add}(2);
+    #t16.{core::List::add}{Invariant}(1);
+    #t16.{core::List::add}{Invariant}(2);
     final core::Iterable<core::int>? #t17 = null;
     if(!#t17.{core::Object::==}(null))
       for (final core::int #t18 in #t17{core::Iterable<core::int>})
-        #t16.{core::List::add}(#t18);
-    #t16.{core::List::add}(3);
+        #t16.{core::List::add}{Invariant}(#t18);
+    #t16.{core::List::add}{Invariant}(3);
   } =>#t16;
   core::Set<core::int>? set = null;
   core::print( block {
     final core::Set<core::int> #t19 = col::LinkedHashSet::•<core::int>();
-    #t19.{core::Set::add}(1);
-    #t19.{core::Set::add}(2);
+    #t19.{core::Set::add}{Invariant}(1);
+    #t19.{core::Set::add}{Invariant}(2);
     final core::Iterable<core::int>? #t20 = set;
     if(!#t20.{core::Object::==}(null))
       for (final core::int #t21 in #t20{core::Iterable<core::int>})
-        #t19.{core::Set::add}(#t21);
-    #t19.{core::Set::add}(3);
+        #t19.{core::Set::add}{Invariant}(#t21);
+    #t19.{core::Set::add}{Invariant}(3);
   } =>#t19);
   core::print( block {
     final core::Set<core::int> #t22 = col::LinkedHashSet::•<core::int>();
-    #t22.{core::Set::add}(1);
-    #t22.{core::Set::add}(2);
+    #t22.{core::Set::add}{Invariant}(1);
+    #t22.{core::Set::add}{Invariant}(2);
     final core::Iterable<core::int>? #t23 = null;
     if(!#t23.{core::Object::==}(null))
       for (final core::int #t24 in #t23{core::Iterable<core::int>})
-        #t22.{core::Set::add}(#t24);
-    #t22.{core::Set::add}(3);
+        #t22.{core::Set::add}{Invariant}(#t24);
+    #t22.{core::Set::add}{Invariant}(3);
   } =>#t22);
   core::Set<core::int> set1 = block {
     final core::Set<core::int> #t25 = col::LinkedHashSet::•<core::int>();
@@ -86,75 +86,75 @@
     if(!#t26.{core::Object::==}(null))
       for (final dynamic #t27 in #t26{core::Iterable<dynamic>}) {
         final core::int #t28 = #t27 as{TypeError,ForNonNullableByDefault} core::int;
-        #t25.{core::Set::add}(#t28);
+        #t25.{core::Set::add}{Invariant}(#t28);
       }
   } =>#t25;
   core::Set<core::int> set3 = block {
     final core::Set<core::int> #t29 = col::LinkedHashSet::•<core::int>();
-    #t29.{core::Set::add}(1);
-    #t29.{core::Set::add}(2);
+    #t29.{core::Set::add}{Invariant}(1);
+    #t29.{core::Set::add}{Invariant}(2);
     final core::Iterable<core::int>? #t30 = set;
     if(!#t30.{core::Object::==}(null))
       for (final core::int #t31 in #t30{core::Iterable<core::int>})
-        #t29.{core::Set::add}(#t31);
-    #t29.{core::Set::add}(3);
+        #t29.{core::Set::add}{Invariant}(#t31);
+    #t29.{core::Set::add}{Invariant}(3);
   } =>#t29;
   core::Set<core::int> set4 = block {
     final core::Set<core::int> #t32 = col::LinkedHashSet::•<core::int>();
-    #t32.{core::Set::add}(1);
-    #t32.{core::Set::add}(2);
+    #t32.{core::Set::add}{Invariant}(1);
+    #t32.{core::Set::add}{Invariant}(2);
     final core::Iterable<core::int>? #t33 = null;
     if(!#t33.{core::Object::==}(null))
       for (final core::int #t34 in #t33{core::Iterable<core::int>})
-        #t32.{core::Set::add}(#t34);
-    #t32.{core::Set::add}(3);
+        #t32.{core::Set::add}{Invariant}(#t34);
+    #t32.{core::Set::add}{Invariant}(3);
   } =>#t32;
   core::Map<core::int, core::int>? map = null;
   core::print( block {
     final core::Map<core::int, core::int> #t35 = <core::int, core::int>{};
-    #t35.{core::Map::[]=}(1, 1);
-    #t35.{core::Map::[]=}(2, 2);
+    #t35.{core::Map::[]=}{Invariant}(1, 1);
+    #t35.{core::Map::[]=}{Invariant}(2, 2);
     final core::Map<core::int, core::int>? #t36 = map;
     if(!#t36.{core::Object::==}(null))
       for (final core::MapEntry<core::int, core::int> #t37 in #t36{core::Map<core::int, core::int>}.{core::Map::entries})
-        #t35.{core::Map::[]=}(#t37.{core::MapEntry::key}, #t37.{core::MapEntry::value});
-    #t35.{core::Map::[]=}(3, 3);
+        #t35.{core::Map::[]=}{Invariant}(#t37.{core::MapEntry::key}, #t37.{core::MapEntry::value});
+    #t35.{core::Map::[]=}{Invariant}(3, 3);
   } =>#t35);
   core::print( block {
     final core::Map<core::int, core::int> #t38 = <core::int, core::int>{};
-    #t38.{core::Map::[]=}(1, 1);
-    #t38.{core::Map::[]=}(2, 2);
+    #t38.{core::Map::[]=}{Invariant}(1, 1);
+    #t38.{core::Map::[]=}{Invariant}(2, 2);
     final core::Map<core::int, core::int>? #t39 = null;
     if(!#t39.{core::Object::==}(null))
       for (final core::MapEntry<core::int, core::int> #t40 in #t39{core::Map<core::int, core::int>}.{core::Map::entries})
-        #t38.{core::Map::[]=}(#t40.{core::MapEntry::key}, #t40.{core::MapEntry::value});
-    #t38.{core::Map::[]=}(3, 3);
+        #t38.{core::Map::[]=}{Invariant}(#t40.{core::MapEntry::key}, #t40.{core::MapEntry::value});
+    #t38.{core::Map::[]=}{Invariant}(3, 3);
   } =>#t38);
   core::Map<core::int, core::int> map1 = block {
     final core::Map<core::int, core::int> #t41 = <core::int, core::int>{};
     final core::Map<core::int, core::int>? #t42 = map;
     if(!#t42.{core::Object::==}(null))
       for (final core::MapEntry<core::int, core::int> #t43 in #t42{core::Map<core::int, core::int>}.{core::Map::entries})
-        #t41.{core::Map::[]=}(#t43.{core::MapEntry::key}, #t43.{core::MapEntry::value});
+        #t41.{core::Map::[]=}{Invariant}(#t43.{core::MapEntry::key}, #t43.{core::MapEntry::value});
   } =>#t41;
   core::Map<core::int, core::int> map3 = block {
     final core::Map<core::int, core::int> #t44 = <core::int, core::int>{};
-    #t44.{core::Map::[]=}(1, 1);
-    #t44.{core::Map::[]=}(2, 2);
+    #t44.{core::Map::[]=}{Invariant}(1, 1);
+    #t44.{core::Map::[]=}{Invariant}(2, 2);
     final core::Map<core::int, core::int>? #t45 = map;
     if(!#t45.{core::Object::==}(null))
       for (final core::MapEntry<core::int, core::int> #t46 in #t45{core::Map<core::int, core::int>}.{core::Map::entries})
-        #t44.{core::Map::[]=}(#t46.{core::MapEntry::key}, #t46.{core::MapEntry::value});
-    #t44.{core::Map::[]=}(3, 3);
+        #t44.{core::Map::[]=}{Invariant}(#t46.{core::MapEntry::key}, #t46.{core::MapEntry::value});
+    #t44.{core::Map::[]=}{Invariant}(3, 3);
   } =>#t44;
   core::Map<core::int, core::int> map4 = block {
     final core::Map<core::int, core::int> #t47 = <core::int, core::int>{};
-    #t47.{core::Map::[]=}(1, 1);
-    #t47.{core::Map::[]=}(2, 2);
+    #t47.{core::Map::[]=}{Invariant}(1, 1);
+    #t47.{core::Map::[]=}{Invariant}(2, 2);
     final core::Map<core::int, core::int>? #t48 = null;
     if(!#t48.{core::Object::==}(null))
       for (final core::MapEntry<core::int, core::int> #t49 in #t48{core::Map<core::int, core::int>}.{core::Map::entries})
-        #t47.{core::Map::[]=}(#t49.{core::MapEntry::key}, #t49.{core::MapEntry::value});
-    #t47.{core::Map::[]=}(3, 3);
+        #t47.{core::Map::[]=}{Invariant}(#t49.{core::MapEntry::key}, #t49.{core::MapEntry::value});
+    #t47.{core::Map::[]=}{Invariant}(3, 3);
   } =>#t47;
 }
diff --git a/pkg/front_end/testcases/nnbd/spread_if_null.dart.strong.transformed.expect b/pkg/front_end/testcases/nnbd/spread_if_null.dart.strong.transformed.expect
index 80f3187..ba1a66c 100644
--- a/pkg/front_end/testcases/nnbd/spread_if_null.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/nnbd/spread_if_null.dart.strong.transformed.expect
@@ -7,31 +7,31 @@
   core::List<core::int>? list = null;
   core::print( block {
     final core::List<core::int> #t1 = <core::int>[];
-    #t1.{core::List::add}(1);
-    #t1.{core::List::add}(2);
+    #t1.{core::List::add}{Invariant}(1);
+    #t1.{core::List::add}{Invariant}(2);
     final core::Iterable<core::int>? #t2 = list;
     if(!#t2.{core::Object::==}(null)) {
       core::Iterator<core::int> :sync-for-iterator = #t2{core::Iterable<core::int>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int #t3 = :sync-for-iterator.{core::Iterator::current};
-        #t1.{core::List::add}(#t3);
+        #t1.{core::List::add}{Invariant}(#t3);
       }
     }
-    #t1.{core::List::add}(3);
+    #t1.{core::List::add}{Invariant}(3);
   } =>#t1);
   core::print( block {
     final core::List<core::int> #t4 = <core::int>[];
-    #t4.{core::List::add}(1);
-    #t4.{core::List::add}(2);
+    #t4.{core::List::add}{Invariant}(1);
+    #t4.{core::List::add}{Invariant}(2);
     final core::Iterable<core::int>? #t5 = null;
     if(!#t5.{core::Object::==}(null)) {
       core::Iterator<core::int> :sync-for-iterator = #t5{core::Iterable<core::int>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int #t6 = :sync-for-iterator.{core::Iterator::current};
-        #t4.{core::List::add}(#t6);
+        #t4.{core::List::add}{Invariant}(#t6);
       }
     }
-    #t4.{core::List::add}(3);
+    #t4.{core::List::add}{Invariant}(3);
   } =>#t4);
   core::List<core::int> list1 = block {
     final core::List<core::int> #t7 = <core::int>[];
@@ -40,7 +40,7 @@
       core::Iterator<core::int> :sync-for-iterator = #t8{core::Iterable<core::int>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int #t9 = :sync-for-iterator.{core::Iterator::current};
-        #t7.{core::List::add}(#t9);
+        #t7.{core::List::add}{Invariant}(#t9);
       }
     }
   } =>#t7;
@@ -51,66 +51,66 @@
       core::Iterator<Never> :sync-for-iterator = #t11{core::Iterable<Never>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final Never #t12 = :sync-for-iterator.{core::Iterator::current};
-        #t10.{core::List::add}(#t12);
+        #t10.{core::List::add}{Invariant}(#t12);
       }
     }
   } =>#t10;
   core::List<core::int> list3 = block {
     final core::List<core::int> #t13 = <core::int>[];
-    #t13.{core::List::add}(1);
-    #t13.{core::List::add}(2);
+    #t13.{core::List::add}{Invariant}(1);
+    #t13.{core::List::add}{Invariant}(2);
     final core::Iterable<core::int>? #t14 = list;
     if(!#t14.{core::Object::==}(null)) {
       core::Iterator<core::int> :sync-for-iterator = #t14{core::Iterable<core::int>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int #t15 = :sync-for-iterator.{core::Iterator::current};
-        #t13.{core::List::add}(#t15);
+        #t13.{core::List::add}{Invariant}(#t15);
       }
     }
-    #t13.{core::List::add}(3);
+    #t13.{core::List::add}{Invariant}(3);
   } =>#t13;
   core::List<core::int> list4 = block {
     final core::List<core::int> #t16 = <core::int>[];
-    #t16.{core::List::add}(1);
-    #t16.{core::List::add}(2);
+    #t16.{core::List::add}{Invariant}(1);
+    #t16.{core::List::add}{Invariant}(2);
     final core::Iterable<core::int>? #t17 = null;
     if(!#t17.{core::Object::==}(null)) {
       core::Iterator<core::int> :sync-for-iterator = #t17{core::Iterable<core::int>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int #t18 = :sync-for-iterator.{core::Iterator::current};
-        #t16.{core::List::add}(#t18);
+        #t16.{core::List::add}{Invariant}(#t18);
       }
     }
-    #t16.{core::List::add}(3);
+    #t16.{core::List::add}{Invariant}(3);
   } =>#t16;
   core::Set<core::int>? set = null;
   core::print( block {
     final core::Set<core::int> #t19 = new col::_CompactLinkedHashSet::•<core::int>();
-    #t19.{core::Set::add}(1);
-    #t19.{core::Set::add}(2);
+    #t19.{core::Set::add}{Invariant}(1);
+    #t19.{core::Set::add}{Invariant}(2);
     final core::Iterable<core::int>? #t20 = set;
     if(!#t20.{core::Object::==}(null)) {
       core::Iterator<core::int> :sync-for-iterator = #t20{core::Iterable<core::int>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int #t21 = :sync-for-iterator.{core::Iterator::current};
-        #t19.{core::Set::add}(#t21);
+        #t19.{core::Set::add}{Invariant}(#t21);
       }
     }
-    #t19.{core::Set::add}(3);
+    #t19.{core::Set::add}{Invariant}(3);
   } =>#t19);
   core::print( block {
     final core::Set<core::int> #t22 = new col::_CompactLinkedHashSet::•<core::int>();
-    #t22.{core::Set::add}(1);
-    #t22.{core::Set::add}(2);
+    #t22.{core::Set::add}{Invariant}(1);
+    #t22.{core::Set::add}{Invariant}(2);
     final core::Iterable<core::int>? #t23 = null;
     if(!#t23.{core::Object::==}(null)) {
       core::Iterator<core::int> :sync-for-iterator = #t23{core::Iterable<core::int>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int #t24 = :sync-for-iterator.{core::Iterator::current};
-        #t22.{core::Set::add}(#t24);
+        #t22.{core::Set::add}{Invariant}(#t24);
       }
     }
-    #t22.{core::Set::add}(3);
+    #t22.{core::Set::add}{Invariant}(3);
   } =>#t22);
   core::Set<core::int> set1 = block {
     final core::Set<core::int> #t25 = new col::_CompactLinkedHashSet::•<core::int>();
@@ -121,67 +121,67 @@
         final dynamic #t27 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int #t28 = #t27 as{TypeError,ForNonNullableByDefault} core::int;
-          #t25.{core::Set::add}(#t28);
+          #t25.{core::Set::add}{Invariant}(#t28);
         }
       }
     }
   } =>#t25;
   core::Set<core::int> set3 = block {
     final core::Set<core::int> #t29 = new col::_CompactLinkedHashSet::•<core::int>();
-    #t29.{core::Set::add}(1);
-    #t29.{core::Set::add}(2);
+    #t29.{core::Set::add}{Invariant}(1);
+    #t29.{core::Set::add}{Invariant}(2);
     final core::Iterable<core::int>? #t30 = set;
     if(!#t30.{core::Object::==}(null)) {
       core::Iterator<core::int> :sync-for-iterator = #t30{core::Iterable<core::int>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int #t31 = :sync-for-iterator.{core::Iterator::current};
-        #t29.{core::Set::add}(#t31);
+        #t29.{core::Set::add}{Invariant}(#t31);
       }
     }
-    #t29.{core::Set::add}(3);
+    #t29.{core::Set::add}{Invariant}(3);
   } =>#t29;
   core::Set<core::int> set4 = block {
     final core::Set<core::int> #t32 = new col::_CompactLinkedHashSet::•<core::int>();
-    #t32.{core::Set::add}(1);
-    #t32.{core::Set::add}(2);
+    #t32.{core::Set::add}{Invariant}(1);
+    #t32.{core::Set::add}{Invariant}(2);
     final core::Iterable<core::int>? #t33 = null;
     if(!#t33.{core::Object::==}(null)) {
       core::Iterator<core::int> :sync-for-iterator = #t33{core::Iterable<core::int>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int #t34 = :sync-for-iterator.{core::Iterator::current};
-        #t32.{core::Set::add}(#t34);
+        #t32.{core::Set::add}{Invariant}(#t34);
       }
     }
-    #t32.{core::Set::add}(3);
+    #t32.{core::Set::add}{Invariant}(3);
   } =>#t32;
   core::Map<core::int, core::int>? map = null;
   core::print( block {
     final core::Map<core::int, core::int> #t35 = <core::int, core::int>{};
-    #t35.{core::Map::[]=}(1, 1);
-    #t35.{core::Map::[]=}(2, 2);
+    #t35.{core::Map::[]=}{Invariant}(1, 1);
+    #t35.{core::Map::[]=}{Invariant}(2, 2);
     final core::Map<core::int, core::int>? #t36 = map;
     if(!#t36.{core::Object::==}(null)) {
       core::Iterator<core::MapEntry<core::int, core::int>> :sync-for-iterator = #t36{core::Map<core::int, core::int>}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::int, core::int> #t37 = :sync-for-iterator.{core::Iterator::current};
-        #t35.{core::Map::[]=}(#t37.{core::MapEntry::key}, #t37.{core::MapEntry::value});
+        #t35.{core::Map::[]=}{Invariant}(#t37.{core::MapEntry::key}, #t37.{core::MapEntry::value});
       }
     }
-    #t35.{core::Map::[]=}(3, 3);
+    #t35.{core::Map::[]=}{Invariant}(3, 3);
   } =>#t35);
   core::print( block {
     final core::Map<core::int, core::int> #t38 = <core::int, core::int>{};
-    #t38.{core::Map::[]=}(1, 1);
-    #t38.{core::Map::[]=}(2, 2);
+    #t38.{core::Map::[]=}{Invariant}(1, 1);
+    #t38.{core::Map::[]=}{Invariant}(2, 2);
     final core::Map<core::int, core::int>? #t39 = null;
     if(!#t39.{core::Object::==}(null)) {
       core::Iterator<core::MapEntry<core::int, core::int>> :sync-for-iterator = #t39{core::Map<core::int, core::int>}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::int, core::int> #t40 = :sync-for-iterator.{core::Iterator::current};
-        #t38.{core::Map::[]=}(#t40.{core::MapEntry::key}, #t40.{core::MapEntry::value});
+        #t38.{core::Map::[]=}{Invariant}(#t40.{core::MapEntry::key}, #t40.{core::MapEntry::value});
       }
     }
-    #t38.{core::Map::[]=}(3, 3);
+    #t38.{core::Map::[]=}{Invariant}(3, 3);
   } =>#t38);
   core::Map<core::int, core::int> map1 = block {
     final core::Map<core::int, core::int> #t41 = <core::int, core::int>{};
@@ -190,36 +190,36 @@
       core::Iterator<core::MapEntry<core::int, core::int>> :sync-for-iterator = #t42{core::Map<core::int, core::int>}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::int, core::int> #t43 = :sync-for-iterator.{core::Iterator::current};
-        #t41.{core::Map::[]=}(#t43.{core::MapEntry::key}, #t43.{core::MapEntry::value});
+        #t41.{core::Map::[]=}{Invariant}(#t43.{core::MapEntry::key}, #t43.{core::MapEntry::value});
       }
     }
   } =>#t41;
   core::Map<core::int, core::int> map3 = block {
     final core::Map<core::int, core::int> #t44 = <core::int, core::int>{};
-    #t44.{core::Map::[]=}(1, 1);
-    #t44.{core::Map::[]=}(2, 2);
+    #t44.{core::Map::[]=}{Invariant}(1, 1);
+    #t44.{core::Map::[]=}{Invariant}(2, 2);
     final core::Map<core::int, core::int>? #t45 = map;
     if(!#t45.{core::Object::==}(null)) {
       core::Iterator<core::MapEntry<core::int, core::int>> :sync-for-iterator = #t45{core::Map<core::int, core::int>}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::int, core::int> #t46 = :sync-for-iterator.{core::Iterator::current};
-        #t44.{core::Map::[]=}(#t46.{core::MapEntry::key}, #t46.{core::MapEntry::value});
+        #t44.{core::Map::[]=}{Invariant}(#t46.{core::MapEntry::key}, #t46.{core::MapEntry::value});
       }
     }
-    #t44.{core::Map::[]=}(3, 3);
+    #t44.{core::Map::[]=}{Invariant}(3, 3);
   } =>#t44;
   core::Map<core::int, core::int> map4 = block {
     final core::Map<core::int, core::int> #t47 = <core::int, core::int>{};
-    #t47.{core::Map::[]=}(1, 1);
-    #t47.{core::Map::[]=}(2, 2);
+    #t47.{core::Map::[]=}{Invariant}(1, 1);
+    #t47.{core::Map::[]=}{Invariant}(2, 2);
     final core::Map<core::int, core::int>? #t48 = null;
     if(!#t48.{core::Object::==}(null)) {
       core::Iterator<core::MapEntry<core::int, core::int>> :sync-for-iterator = #t48{core::Map<core::int, core::int>}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::int, core::int> #t49 = :sync-for-iterator.{core::Iterator::current};
-        #t47.{core::Map::[]=}(#t49.{core::MapEntry::key}, #t49.{core::MapEntry::value});
+        #t47.{core::Map::[]=}{Invariant}(#t49.{core::MapEntry::key}, #t49.{core::MapEntry::value});
       }
     }
-    #t47.{core::Map::[]=}(3, 3);
+    #t47.{core::Map::[]=}{Invariant}(3, 3);
   } =>#t47;
 }
diff --git a/pkg/front_end/testcases/nnbd/spread_if_null.dart.weak.expect b/pkg/front_end/testcases/nnbd/spread_if_null.dart.weak.expect
index 04612a2..ffceca9 100644
--- a/pkg/front_end/testcases/nnbd/spread_if_null.dart.weak.expect
+++ b/pkg/front_end/testcases/nnbd/spread_if_null.dart.weak.expect
@@ -7,78 +7,78 @@
   core::List<core::int>? list = null;
   core::print( block {
     final core::List<core::int> #t1 = <core::int>[];
-    #t1.{core::List::add}(1);
-    #t1.{core::List::add}(2);
+    #t1.{core::List::add}{Invariant}(1);
+    #t1.{core::List::add}{Invariant}(2);
     final core::Iterable<core::int>? #t2 = list;
     if(!#t2.{core::Object::==}(null))
       for (final core::int #t3 in #t2{core::Iterable<core::int>})
-        #t1.{core::List::add}(#t3);
-    #t1.{core::List::add}(3);
+        #t1.{core::List::add}{Invariant}(#t3);
+    #t1.{core::List::add}{Invariant}(3);
   } =>#t1);
   core::print( block {
     final core::List<core::int> #t4 = <core::int>[];
-    #t4.{core::List::add}(1);
-    #t4.{core::List::add}(2);
+    #t4.{core::List::add}{Invariant}(1);
+    #t4.{core::List::add}{Invariant}(2);
     final core::Iterable<core::int>? #t5 = null;
     if(!#t5.{core::Object::==}(null))
       for (final core::int #t6 in #t5{core::Iterable<core::int>})
-        #t4.{core::List::add}(#t6);
-    #t4.{core::List::add}(3);
+        #t4.{core::List::add}{Invariant}(#t6);
+    #t4.{core::List::add}{Invariant}(3);
   } =>#t4);
   core::List<core::int> list1 = block {
     final core::List<core::int> #t7 = <core::int>[];
     final core::Iterable<core::int>? #t8 = list;
     if(!#t8.{core::Object::==}(null))
       for (final core::int #t9 in #t8{core::Iterable<core::int>})
-        #t7.{core::List::add}(#t9);
+        #t7.{core::List::add}{Invariant}(#t9);
   } =>#t7;
   core::List<Never> list2 = block {
     final core::List<Never> #t10 = <Never>[];
     final core::Iterable<Never>? #t11 = null;
     if(!#t11.{core::Object::==}(null))
       for (final Never #t12 in #t11{core::Iterable<Never>})
-        #t10.{core::List::add}(#t12);
+        #t10.{core::List::add}{Invariant}(#t12);
   } =>#t10;
   core::List<core::int> list3 = block {
     final core::List<core::int> #t13 = <core::int>[];
-    #t13.{core::List::add}(1);
-    #t13.{core::List::add}(2);
+    #t13.{core::List::add}{Invariant}(1);
+    #t13.{core::List::add}{Invariant}(2);
     final core::Iterable<core::int>? #t14 = list;
     if(!#t14.{core::Object::==}(null))
       for (final core::int #t15 in #t14{core::Iterable<core::int>})
-        #t13.{core::List::add}(#t15);
-    #t13.{core::List::add}(3);
+        #t13.{core::List::add}{Invariant}(#t15);
+    #t13.{core::List::add}{Invariant}(3);
   } =>#t13;
   core::List<core::int> list4 = block {
     final core::List<core::int> #t16 = <core::int>[];
-    #t16.{core::List::add}(1);
-    #t16.{core::List::add}(2);
+    #t16.{core::List::add}{Invariant}(1);
+    #t16.{core::List::add}{Invariant}(2);
     final core::Iterable<core::int>? #t17 = null;
     if(!#t17.{core::Object::==}(null))
       for (final core::int #t18 in #t17{core::Iterable<core::int>})
-        #t16.{core::List::add}(#t18);
-    #t16.{core::List::add}(3);
+        #t16.{core::List::add}{Invariant}(#t18);
+    #t16.{core::List::add}{Invariant}(3);
   } =>#t16;
   core::Set<core::int>? set = null;
   core::print( block {
     final core::Set<core::int> #t19 = col::LinkedHashSet::•<core::int>();
-    #t19.{core::Set::add}(1);
-    #t19.{core::Set::add}(2);
+    #t19.{core::Set::add}{Invariant}(1);
+    #t19.{core::Set::add}{Invariant}(2);
     final core::Iterable<core::int>? #t20 = set;
     if(!#t20.{core::Object::==}(null))
       for (final core::int #t21 in #t20{core::Iterable<core::int>})
-        #t19.{core::Set::add}(#t21);
-    #t19.{core::Set::add}(3);
+        #t19.{core::Set::add}{Invariant}(#t21);
+    #t19.{core::Set::add}{Invariant}(3);
   } =>#t19);
   core::print( block {
     final core::Set<core::int> #t22 = col::LinkedHashSet::•<core::int>();
-    #t22.{core::Set::add}(1);
-    #t22.{core::Set::add}(2);
+    #t22.{core::Set::add}{Invariant}(1);
+    #t22.{core::Set::add}{Invariant}(2);
     final core::Iterable<core::int>? #t23 = null;
     if(!#t23.{core::Object::==}(null))
       for (final core::int #t24 in #t23{core::Iterable<core::int>})
-        #t22.{core::Set::add}(#t24);
-    #t22.{core::Set::add}(3);
+        #t22.{core::Set::add}{Invariant}(#t24);
+    #t22.{core::Set::add}{Invariant}(3);
   } =>#t22);
   core::Set<core::int> set1 = block {
     final core::Set<core::int> #t25 = col::LinkedHashSet::•<core::int>();
@@ -86,75 +86,75 @@
     if(!#t26.{core::Object::==}(null))
       for (final dynamic #t27 in #t26{core::Iterable<dynamic>}) {
         final core::int #t28 = #t27 as{TypeError,ForNonNullableByDefault} core::int;
-        #t25.{core::Set::add}(#t28);
+        #t25.{core::Set::add}{Invariant}(#t28);
       }
   } =>#t25;
   core::Set<core::int> set3 = block {
     final core::Set<core::int> #t29 = col::LinkedHashSet::•<core::int>();
-    #t29.{core::Set::add}(1);
-    #t29.{core::Set::add}(2);
+    #t29.{core::Set::add}{Invariant}(1);
+    #t29.{core::Set::add}{Invariant}(2);
     final core::Iterable<core::int>? #t30 = set;
     if(!#t30.{core::Object::==}(null))
       for (final core::int #t31 in #t30{core::Iterable<core::int>})
-        #t29.{core::Set::add}(#t31);
-    #t29.{core::Set::add}(3);
+        #t29.{core::Set::add}{Invariant}(#t31);
+    #t29.{core::Set::add}{Invariant}(3);
   } =>#t29;
   core::Set<core::int> set4 = block {
     final core::Set<core::int> #t32 = col::LinkedHashSet::•<core::int>();
-    #t32.{core::Set::add}(1);
-    #t32.{core::Set::add}(2);
+    #t32.{core::Set::add}{Invariant}(1);
+    #t32.{core::Set::add}{Invariant}(2);
     final core::Iterable<core::int>? #t33 = null;
     if(!#t33.{core::Object::==}(null))
       for (final core::int #t34 in #t33{core::Iterable<core::int>})
-        #t32.{core::Set::add}(#t34);
-    #t32.{core::Set::add}(3);
+        #t32.{core::Set::add}{Invariant}(#t34);
+    #t32.{core::Set::add}{Invariant}(3);
   } =>#t32;
   core::Map<core::int, core::int>? map = null;
   core::print( block {
     final core::Map<core::int, core::int> #t35 = <core::int, core::int>{};
-    #t35.{core::Map::[]=}(1, 1);
-    #t35.{core::Map::[]=}(2, 2);
+    #t35.{core::Map::[]=}{Invariant}(1, 1);
+    #t35.{core::Map::[]=}{Invariant}(2, 2);
     final core::Map<core::int, core::int>? #t36 = map;
     if(!#t36.{core::Object::==}(null))
       for (final core::MapEntry<core::int, core::int> #t37 in #t36{core::Map<core::int, core::int>}.{core::Map::entries})
-        #t35.{core::Map::[]=}(#t37.{core::MapEntry::key}, #t37.{core::MapEntry::value});
-    #t35.{core::Map::[]=}(3, 3);
+        #t35.{core::Map::[]=}{Invariant}(#t37.{core::MapEntry::key}, #t37.{core::MapEntry::value});
+    #t35.{core::Map::[]=}{Invariant}(3, 3);
   } =>#t35);
   core::print( block {
     final core::Map<core::int, core::int> #t38 = <core::int, core::int>{};
-    #t38.{core::Map::[]=}(1, 1);
-    #t38.{core::Map::[]=}(2, 2);
+    #t38.{core::Map::[]=}{Invariant}(1, 1);
+    #t38.{core::Map::[]=}{Invariant}(2, 2);
     final core::Map<core::int, core::int>? #t39 = null;
     if(!#t39.{core::Object::==}(null))
       for (final core::MapEntry<core::int, core::int> #t40 in #t39{core::Map<core::int, core::int>}.{core::Map::entries})
-        #t38.{core::Map::[]=}(#t40.{core::MapEntry::key}, #t40.{core::MapEntry::value});
-    #t38.{core::Map::[]=}(3, 3);
+        #t38.{core::Map::[]=}{Invariant}(#t40.{core::MapEntry::key}, #t40.{core::MapEntry::value});
+    #t38.{core::Map::[]=}{Invariant}(3, 3);
   } =>#t38);
   core::Map<core::int, core::int> map1 = block {
     final core::Map<core::int, core::int> #t41 = <core::int, core::int>{};
     final core::Map<core::int, core::int>? #t42 = map;
     if(!#t42.{core::Object::==}(null))
       for (final core::MapEntry<core::int, core::int> #t43 in #t42{core::Map<core::int, core::int>}.{core::Map::entries})
-        #t41.{core::Map::[]=}(#t43.{core::MapEntry::key}, #t43.{core::MapEntry::value});
+        #t41.{core::Map::[]=}{Invariant}(#t43.{core::MapEntry::key}, #t43.{core::MapEntry::value});
   } =>#t41;
   core::Map<core::int, core::int> map3 = block {
     final core::Map<core::int, core::int> #t44 = <core::int, core::int>{};
-    #t44.{core::Map::[]=}(1, 1);
-    #t44.{core::Map::[]=}(2, 2);
+    #t44.{core::Map::[]=}{Invariant}(1, 1);
+    #t44.{core::Map::[]=}{Invariant}(2, 2);
     final core::Map<core::int, core::int>? #t45 = map;
     if(!#t45.{core::Object::==}(null))
       for (final core::MapEntry<core::int, core::int> #t46 in #t45{core::Map<core::int, core::int>}.{core::Map::entries})
-        #t44.{core::Map::[]=}(#t46.{core::MapEntry::key}, #t46.{core::MapEntry::value});
-    #t44.{core::Map::[]=}(3, 3);
+        #t44.{core::Map::[]=}{Invariant}(#t46.{core::MapEntry::key}, #t46.{core::MapEntry::value});
+    #t44.{core::Map::[]=}{Invariant}(3, 3);
   } =>#t44;
   core::Map<core::int, core::int> map4 = block {
     final core::Map<core::int, core::int> #t47 = <core::int, core::int>{};
-    #t47.{core::Map::[]=}(1, 1);
-    #t47.{core::Map::[]=}(2, 2);
+    #t47.{core::Map::[]=}{Invariant}(1, 1);
+    #t47.{core::Map::[]=}{Invariant}(2, 2);
     final core::Map<core::int, core::int>? #t48 = null;
     if(!#t48.{core::Object::==}(null))
       for (final core::MapEntry<core::int, core::int> #t49 in #t48{core::Map<core::int, core::int>}.{core::Map::entries})
-        #t47.{core::Map::[]=}(#t49.{core::MapEntry::key}, #t49.{core::MapEntry::value});
-    #t47.{core::Map::[]=}(3, 3);
+        #t47.{core::Map::[]=}{Invariant}(#t49.{core::MapEntry::key}, #t49.{core::MapEntry::value});
+    #t47.{core::Map::[]=}{Invariant}(3, 3);
   } =>#t47;
 }
diff --git a/pkg/front_end/testcases/nnbd/spread_if_null.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd/spread_if_null.dart.weak.transformed.expect
index 80f3187..ba1a66c 100644
--- a/pkg/front_end/testcases/nnbd/spread_if_null.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/nnbd/spread_if_null.dart.weak.transformed.expect
@@ -7,31 +7,31 @@
   core::List<core::int>? list = null;
   core::print( block {
     final core::List<core::int> #t1 = <core::int>[];
-    #t1.{core::List::add}(1);
-    #t1.{core::List::add}(2);
+    #t1.{core::List::add}{Invariant}(1);
+    #t1.{core::List::add}{Invariant}(2);
     final core::Iterable<core::int>? #t2 = list;
     if(!#t2.{core::Object::==}(null)) {
       core::Iterator<core::int> :sync-for-iterator = #t2{core::Iterable<core::int>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int #t3 = :sync-for-iterator.{core::Iterator::current};
-        #t1.{core::List::add}(#t3);
+        #t1.{core::List::add}{Invariant}(#t3);
       }
     }
-    #t1.{core::List::add}(3);
+    #t1.{core::List::add}{Invariant}(3);
   } =>#t1);
   core::print( block {
     final core::List<core::int> #t4 = <core::int>[];
-    #t4.{core::List::add}(1);
-    #t4.{core::List::add}(2);
+    #t4.{core::List::add}{Invariant}(1);
+    #t4.{core::List::add}{Invariant}(2);
     final core::Iterable<core::int>? #t5 = null;
     if(!#t5.{core::Object::==}(null)) {
       core::Iterator<core::int> :sync-for-iterator = #t5{core::Iterable<core::int>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int #t6 = :sync-for-iterator.{core::Iterator::current};
-        #t4.{core::List::add}(#t6);
+        #t4.{core::List::add}{Invariant}(#t6);
       }
     }
-    #t4.{core::List::add}(3);
+    #t4.{core::List::add}{Invariant}(3);
   } =>#t4);
   core::List<core::int> list1 = block {
     final core::List<core::int> #t7 = <core::int>[];
@@ -40,7 +40,7 @@
       core::Iterator<core::int> :sync-for-iterator = #t8{core::Iterable<core::int>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int #t9 = :sync-for-iterator.{core::Iterator::current};
-        #t7.{core::List::add}(#t9);
+        #t7.{core::List::add}{Invariant}(#t9);
       }
     }
   } =>#t7;
@@ -51,66 +51,66 @@
       core::Iterator<Never> :sync-for-iterator = #t11{core::Iterable<Never>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final Never #t12 = :sync-for-iterator.{core::Iterator::current};
-        #t10.{core::List::add}(#t12);
+        #t10.{core::List::add}{Invariant}(#t12);
       }
     }
   } =>#t10;
   core::List<core::int> list3 = block {
     final core::List<core::int> #t13 = <core::int>[];
-    #t13.{core::List::add}(1);
-    #t13.{core::List::add}(2);
+    #t13.{core::List::add}{Invariant}(1);
+    #t13.{core::List::add}{Invariant}(2);
     final core::Iterable<core::int>? #t14 = list;
     if(!#t14.{core::Object::==}(null)) {
       core::Iterator<core::int> :sync-for-iterator = #t14{core::Iterable<core::int>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int #t15 = :sync-for-iterator.{core::Iterator::current};
-        #t13.{core::List::add}(#t15);
+        #t13.{core::List::add}{Invariant}(#t15);
       }
     }
-    #t13.{core::List::add}(3);
+    #t13.{core::List::add}{Invariant}(3);
   } =>#t13;
   core::List<core::int> list4 = block {
     final core::List<core::int> #t16 = <core::int>[];
-    #t16.{core::List::add}(1);
-    #t16.{core::List::add}(2);
+    #t16.{core::List::add}{Invariant}(1);
+    #t16.{core::List::add}{Invariant}(2);
     final core::Iterable<core::int>? #t17 = null;
     if(!#t17.{core::Object::==}(null)) {
       core::Iterator<core::int> :sync-for-iterator = #t17{core::Iterable<core::int>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int #t18 = :sync-for-iterator.{core::Iterator::current};
-        #t16.{core::List::add}(#t18);
+        #t16.{core::List::add}{Invariant}(#t18);
       }
     }
-    #t16.{core::List::add}(3);
+    #t16.{core::List::add}{Invariant}(3);
   } =>#t16;
   core::Set<core::int>? set = null;
   core::print( block {
     final core::Set<core::int> #t19 = new col::_CompactLinkedHashSet::•<core::int>();
-    #t19.{core::Set::add}(1);
-    #t19.{core::Set::add}(2);
+    #t19.{core::Set::add}{Invariant}(1);
+    #t19.{core::Set::add}{Invariant}(2);
     final core::Iterable<core::int>? #t20 = set;
     if(!#t20.{core::Object::==}(null)) {
       core::Iterator<core::int> :sync-for-iterator = #t20{core::Iterable<core::int>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int #t21 = :sync-for-iterator.{core::Iterator::current};
-        #t19.{core::Set::add}(#t21);
+        #t19.{core::Set::add}{Invariant}(#t21);
       }
     }
-    #t19.{core::Set::add}(3);
+    #t19.{core::Set::add}{Invariant}(3);
   } =>#t19);
   core::print( block {
     final core::Set<core::int> #t22 = new col::_CompactLinkedHashSet::•<core::int>();
-    #t22.{core::Set::add}(1);
-    #t22.{core::Set::add}(2);
+    #t22.{core::Set::add}{Invariant}(1);
+    #t22.{core::Set::add}{Invariant}(2);
     final core::Iterable<core::int>? #t23 = null;
     if(!#t23.{core::Object::==}(null)) {
       core::Iterator<core::int> :sync-for-iterator = #t23{core::Iterable<core::int>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int #t24 = :sync-for-iterator.{core::Iterator::current};
-        #t22.{core::Set::add}(#t24);
+        #t22.{core::Set::add}{Invariant}(#t24);
       }
     }
-    #t22.{core::Set::add}(3);
+    #t22.{core::Set::add}{Invariant}(3);
   } =>#t22);
   core::Set<core::int> set1 = block {
     final core::Set<core::int> #t25 = new col::_CompactLinkedHashSet::•<core::int>();
@@ -121,67 +121,67 @@
         final dynamic #t27 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int #t28 = #t27 as{TypeError,ForNonNullableByDefault} core::int;
-          #t25.{core::Set::add}(#t28);
+          #t25.{core::Set::add}{Invariant}(#t28);
         }
       }
     }
   } =>#t25;
   core::Set<core::int> set3 = block {
     final core::Set<core::int> #t29 = new col::_CompactLinkedHashSet::•<core::int>();
-    #t29.{core::Set::add}(1);
-    #t29.{core::Set::add}(2);
+    #t29.{core::Set::add}{Invariant}(1);
+    #t29.{core::Set::add}{Invariant}(2);
     final core::Iterable<core::int>? #t30 = set;
     if(!#t30.{core::Object::==}(null)) {
       core::Iterator<core::int> :sync-for-iterator = #t30{core::Iterable<core::int>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int #t31 = :sync-for-iterator.{core::Iterator::current};
-        #t29.{core::Set::add}(#t31);
+        #t29.{core::Set::add}{Invariant}(#t31);
       }
     }
-    #t29.{core::Set::add}(3);
+    #t29.{core::Set::add}{Invariant}(3);
   } =>#t29;
   core::Set<core::int> set4 = block {
     final core::Set<core::int> #t32 = new col::_CompactLinkedHashSet::•<core::int>();
-    #t32.{core::Set::add}(1);
-    #t32.{core::Set::add}(2);
+    #t32.{core::Set::add}{Invariant}(1);
+    #t32.{core::Set::add}{Invariant}(2);
     final core::Iterable<core::int>? #t33 = null;
     if(!#t33.{core::Object::==}(null)) {
       core::Iterator<core::int> :sync-for-iterator = #t33{core::Iterable<core::int>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::int #t34 = :sync-for-iterator.{core::Iterator::current};
-        #t32.{core::Set::add}(#t34);
+        #t32.{core::Set::add}{Invariant}(#t34);
       }
     }
-    #t32.{core::Set::add}(3);
+    #t32.{core::Set::add}{Invariant}(3);
   } =>#t32;
   core::Map<core::int, core::int>? map = null;
   core::print( block {
     final core::Map<core::int, core::int> #t35 = <core::int, core::int>{};
-    #t35.{core::Map::[]=}(1, 1);
-    #t35.{core::Map::[]=}(2, 2);
+    #t35.{core::Map::[]=}{Invariant}(1, 1);
+    #t35.{core::Map::[]=}{Invariant}(2, 2);
     final core::Map<core::int, core::int>? #t36 = map;
     if(!#t36.{core::Object::==}(null)) {
       core::Iterator<core::MapEntry<core::int, core::int>> :sync-for-iterator = #t36{core::Map<core::int, core::int>}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::int, core::int> #t37 = :sync-for-iterator.{core::Iterator::current};
-        #t35.{core::Map::[]=}(#t37.{core::MapEntry::key}, #t37.{core::MapEntry::value});
+        #t35.{core::Map::[]=}{Invariant}(#t37.{core::MapEntry::key}, #t37.{core::MapEntry::value});
       }
     }
-    #t35.{core::Map::[]=}(3, 3);
+    #t35.{core::Map::[]=}{Invariant}(3, 3);
   } =>#t35);
   core::print( block {
     final core::Map<core::int, core::int> #t38 = <core::int, core::int>{};
-    #t38.{core::Map::[]=}(1, 1);
-    #t38.{core::Map::[]=}(2, 2);
+    #t38.{core::Map::[]=}{Invariant}(1, 1);
+    #t38.{core::Map::[]=}{Invariant}(2, 2);
     final core::Map<core::int, core::int>? #t39 = null;
     if(!#t39.{core::Object::==}(null)) {
       core::Iterator<core::MapEntry<core::int, core::int>> :sync-for-iterator = #t39{core::Map<core::int, core::int>}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::int, core::int> #t40 = :sync-for-iterator.{core::Iterator::current};
-        #t38.{core::Map::[]=}(#t40.{core::MapEntry::key}, #t40.{core::MapEntry::value});
+        #t38.{core::Map::[]=}{Invariant}(#t40.{core::MapEntry::key}, #t40.{core::MapEntry::value});
       }
     }
-    #t38.{core::Map::[]=}(3, 3);
+    #t38.{core::Map::[]=}{Invariant}(3, 3);
   } =>#t38);
   core::Map<core::int, core::int> map1 = block {
     final core::Map<core::int, core::int> #t41 = <core::int, core::int>{};
@@ -190,36 +190,36 @@
       core::Iterator<core::MapEntry<core::int, core::int>> :sync-for-iterator = #t42{core::Map<core::int, core::int>}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::int, core::int> #t43 = :sync-for-iterator.{core::Iterator::current};
-        #t41.{core::Map::[]=}(#t43.{core::MapEntry::key}, #t43.{core::MapEntry::value});
+        #t41.{core::Map::[]=}{Invariant}(#t43.{core::MapEntry::key}, #t43.{core::MapEntry::value});
       }
     }
   } =>#t41;
   core::Map<core::int, core::int> map3 = block {
     final core::Map<core::int, core::int> #t44 = <core::int, core::int>{};
-    #t44.{core::Map::[]=}(1, 1);
-    #t44.{core::Map::[]=}(2, 2);
+    #t44.{core::Map::[]=}{Invariant}(1, 1);
+    #t44.{core::Map::[]=}{Invariant}(2, 2);
     final core::Map<core::int, core::int>? #t45 = map;
     if(!#t45.{core::Object::==}(null)) {
       core::Iterator<core::MapEntry<core::int, core::int>> :sync-for-iterator = #t45{core::Map<core::int, core::int>}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::int, core::int> #t46 = :sync-for-iterator.{core::Iterator::current};
-        #t44.{core::Map::[]=}(#t46.{core::MapEntry::key}, #t46.{core::MapEntry::value});
+        #t44.{core::Map::[]=}{Invariant}(#t46.{core::MapEntry::key}, #t46.{core::MapEntry::value});
       }
     }
-    #t44.{core::Map::[]=}(3, 3);
+    #t44.{core::Map::[]=}{Invariant}(3, 3);
   } =>#t44;
   core::Map<core::int, core::int> map4 = block {
     final core::Map<core::int, core::int> #t47 = <core::int, core::int>{};
-    #t47.{core::Map::[]=}(1, 1);
-    #t47.{core::Map::[]=}(2, 2);
+    #t47.{core::Map::[]=}{Invariant}(1, 1);
+    #t47.{core::Map::[]=}{Invariant}(2, 2);
     final core::Map<core::int, core::int>? #t48 = null;
     if(!#t48.{core::Object::==}(null)) {
       core::Iterator<core::MapEntry<core::int, core::int>> :sync-for-iterator = #t48{core::Map<core::int, core::int>}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::int, core::int> #t49 = :sync-for-iterator.{core::Iterator::current};
-        #t47.{core::Map::[]=}(#t49.{core::MapEntry::key}, #t49.{core::MapEntry::value});
+        #t47.{core::Map::[]=}{Invariant}(#t49.{core::MapEntry::key}, #t49.{core::MapEntry::value});
       }
     }
-    #t47.{core::Map::[]=}(3, 3);
+    #t47.{core::Map::[]=}{Invariant}(3, 3);
   } =>#t47;
 }
diff --git a/pkg/front_end/testcases/nnbd/strictly_non_nullable_warnings.dart.strong.expect b/pkg/front_end/testcases/nnbd/strictly_non_nullable_warnings.dart.strong.expect
index dc3e70c..a97650d 100644
--- a/pkg/front_end/testcases/nnbd/strictly_non_nullable_warnings.dart.strong.expect
+++ b/pkg/front_end/testcases/nnbd/strictly_non_nullable_warnings.dart.strong.expect
@@ -142,7 +142,7 @@
     final core::Iterable<core::String>? #t6 = l;
     if(!#t6.{core::Object::==}(null))
       for (final core::String #t7 in #t6{core::Iterable<core::String>})
-        #t5.{core::List::add}(#t7);
+        #t5.{core::List::add}{Invariant}(#t7);
   } =>#t5;
   core::Set<core::String> a = block {
     final core::Set<core::String> #t8 = col::LinkedHashSet::•<core::String>();
@@ -150,7 +150,7 @@
     if(!#t9.{core::Object::==}(null))
       for (final dynamic #t10 in #t9{core::Iterable<dynamic>}) {
         final core::String #t11 = #t10 as{TypeError,ForNonNullableByDefault} core::String;
-        #t8.{core::Set::add}(#t11);
+        #t8.{core::Set::add}{Invariant}(#t11);
       }
   } =>#t8;
   block {
@@ -158,21 +158,21 @@
     final core::Iterable<core::String>? #t13 = l;
     if(!#t13.{core::Object::==}(null))
       for (final core::String #t14 in #t13{core::Iterable<core::String>})
-        #t12.{core::Set::add}(#t14);
+        #t12.{core::Set::add}{Invariant}(#t14);
   } =>#t12;
   core::Map<core::String, core::int> b = block {
     final core::Map<core::String, core::int> #t15 = <core::String, core::int>{};
     final core::Map<core::String, core::int>? #t16 = m;
     if(!#t16.{core::Object::==}(null))
       for (final core::MapEntry<core::String, core::int> #t17 in #t16{core::Map<core::String, core::int>}.{core::Map::entries})
-        #t15.{core::Map::[]=}(#t17.{core::MapEntry::key}, #t17.{core::MapEntry::value});
+        #t15.{core::Map::[]=}{Invariant}(#t17.{core::MapEntry::key}, #t17.{core::MapEntry::value});
   } =>#t15;
   block {
     final core::Map<core::String, core::int> #t18 = <core::String, core::int>{};
     final core::Map<core::String, core::int>? #t19 = m;
     if(!#t19.{core::Object::==}(null))
       for (final core::MapEntry<core::String, core::int> #t20 in #t19{core::Map<core::String, core::int>}.{core::Map::entries})
-        #t18.{core::Map::[]=}(#t20.{core::MapEntry::key}, #t20.{core::MapEntry::value});
+        #t18.{core::Map::[]=}{Invariant}(#t20.{core::MapEntry::key}, #t20.{core::MapEntry::value});
   } =>#t18;
   s!;
   let final core::String #t21 = s in #t21.{core::String::==}(null) ?{core::String?} null : #t21.{core::String::substring}(0, 0);
diff --git a/pkg/front_end/testcases/nnbd/strictly_non_nullable_warnings.dart.strong.transformed.expect b/pkg/front_end/testcases/nnbd/strictly_non_nullable_warnings.dart.strong.transformed.expect
index 87930a9..df0ca83 100644
--- a/pkg/front_end/testcases/nnbd/strictly_non_nullable_warnings.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/nnbd/strictly_non_nullable_warnings.dart.strong.transformed.expect
@@ -144,7 +144,7 @@
       core::Iterator<core::String> :sync-for-iterator = #t6{core::Iterable<core::String>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::String #t7 = :sync-for-iterator.{core::Iterator::current};
-        #t5.{core::List::add}(#t7);
+        #t5.{core::List::add}{Invariant}(#t7);
       }
     }
   } =>#t5;
@@ -157,7 +157,7 @@
         final dynamic #t10 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::String #t11 = #t10 as{TypeError,ForNonNullableByDefault} core::String;
-          #t8.{core::Set::add}(#t11);
+          #t8.{core::Set::add}{Invariant}(#t11);
         }
       }
     }
@@ -169,7 +169,7 @@
       core::Iterator<core::String> :sync-for-iterator = #t13{core::Iterable<core::String>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::String #t14 = :sync-for-iterator.{core::Iterator::current};
-        #t12.{core::Set::add}(#t14);
+        #t12.{core::Set::add}{Invariant}(#t14);
       }
     }
   } =>#t12;
@@ -180,7 +180,7 @@
       core::Iterator<core::MapEntry<core::String, core::int>> :sync-for-iterator = #t16{core::Map<core::String, core::int>}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String, core::int> #t17 = :sync-for-iterator.{core::Iterator::current};
-        #t15.{core::Map::[]=}(#t17.{core::MapEntry::key}, #t17.{core::MapEntry::value});
+        #t15.{core::Map::[]=}{Invariant}(#t17.{core::MapEntry::key}, #t17.{core::MapEntry::value});
       }
     }
   } =>#t15;
@@ -191,7 +191,7 @@
       core::Iterator<core::MapEntry<core::String, core::int>> :sync-for-iterator = #t19{core::Map<core::String, core::int>}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String, core::int> #t20 = :sync-for-iterator.{core::Iterator::current};
-        #t18.{core::Map::[]=}(#t20.{core::MapEntry::key}, #t20.{core::MapEntry::value});
+        #t18.{core::Map::[]=}{Invariant}(#t20.{core::MapEntry::key}, #t20.{core::MapEntry::value});
       }
     }
   } =>#t18;
diff --git a/pkg/front_end/testcases/nnbd/strictly_non_nullable_warnings.dart.weak.expect b/pkg/front_end/testcases/nnbd/strictly_non_nullable_warnings.dart.weak.expect
index dc3e70c..a97650d 100644
--- a/pkg/front_end/testcases/nnbd/strictly_non_nullable_warnings.dart.weak.expect
+++ b/pkg/front_end/testcases/nnbd/strictly_non_nullable_warnings.dart.weak.expect
@@ -142,7 +142,7 @@
     final core::Iterable<core::String>? #t6 = l;
     if(!#t6.{core::Object::==}(null))
       for (final core::String #t7 in #t6{core::Iterable<core::String>})
-        #t5.{core::List::add}(#t7);
+        #t5.{core::List::add}{Invariant}(#t7);
   } =>#t5;
   core::Set<core::String> a = block {
     final core::Set<core::String> #t8 = col::LinkedHashSet::•<core::String>();
@@ -150,7 +150,7 @@
     if(!#t9.{core::Object::==}(null))
       for (final dynamic #t10 in #t9{core::Iterable<dynamic>}) {
         final core::String #t11 = #t10 as{TypeError,ForNonNullableByDefault} core::String;
-        #t8.{core::Set::add}(#t11);
+        #t8.{core::Set::add}{Invariant}(#t11);
       }
   } =>#t8;
   block {
@@ -158,21 +158,21 @@
     final core::Iterable<core::String>? #t13 = l;
     if(!#t13.{core::Object::==}(null))
       for (final core::String #t14 in #t13{core::Iterable<core::String>})
-        #t12.{core::Set::add}(#t14);
+        #t12.{core::Set::add}{Invariant}(#t14);
   } =>#t12;
   core::Map<core::String, core::int> b = block {
     final core::Map<core::String, core::int> #t15 = <core::String, core::int>{};
     final core::Map<core::String, core::int>? #t16 = m;
     if(!#t16.{core::Object::==}(null))
       for (final core::MapEntry<core::String, core::int> #t17 in #t16{core::Map<core::String, core::int>}.{core::Map::entries})
-        #t15.{core::Map::[]=}(#t17.{core::MapEntry::key}, #t17.{core::MapEntry::value});
+        #t15.{core::Map::[]=}{Invariant}(#t17.{core::MapEntry::key}, #t17.{core::MapEntry::value});
   } =>#t15;
   block {
     final core::Map<core::String, core::int> #t18 = <core::String, core::int>{};
     final core::Map<core::String, core::int>? #t19 = m;
     if(!#t19.{core::Object::==}(null))
       for (final core::MapEntry<core::String, core::int> #t20 in #t19{core::Map<core::String, core::int>}.{core::Map::entries})
-        #t18.{core::Map::[]=}(#t20.{core::MapEntry::key}, #t20.{core::MapEntry::value});
+        #t18.{core::Map::[]=}{Invariant}(#t20.{core::MapEntry::key}, #t20.{core::MapEntry::value});
   } =>#t18;
   s!;
   let final core::String #t21 = s in #t21.{core::String::==}(null) ?{core::String?} null : #t21.{core::String::substring}(0, 0);
diff --git a/pkg/front_end/testcases/nnbd/strictly_non_nullable_warnings.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd/strictly_non_nullable_warnings.dart.weak.transformed.expect
index 87930a9..df0ca83 100644
--- a/pkg/front_end/testcases/nnbd/strictly_non_nullable_warnings.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/nnbd/strictly_non_nullable_warnings.dart.weak.transformed.expect
@@ -144,7 +144,7 @@
       core::Iterator<core::String> :sync-for-iterator = #t6{core::Iterable<core::String>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::String #t7 = :sync-for-iterator.{core::Iterator::current};
-        #t5.{core::List::add}(#t7);
+        #t5.{core::List::add}{Invariant}(#t7);
       }
     }
   } =>#t5;
@@ -157,7 +157,7 @@
         final dynamic #t10 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::String #t11 = #t10 as{TypeError,ForNonNullableByDefault} core::String;
-          #t8.{core::Set::add}(#t11);
+          #t8.{core::Set::add}{Invariant}(#t11);
         }
       }
     }
@@ -169,7 +169,7 @@
       core::Iterator<core::String> :sync-for-iterator = #t13{core::Iterable<core::String>}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::String #t14 = :sync-for-iterator.{core::Iterator::current};
-        #t12.{core::Set::add}(#t14);
+        #t12.{core::Set::add}{Invariant}(#t14);
       }
     }
   } =>#t12;
@@ -180,7 +180,7 @@
       core::Iterator<core::MapEntry<core::String, core::int>> :sync-for-iterator = #t16{core::Map<core::String, core::int>}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String, core::int> #t17 = :sync-for-iterator.{core::Iterator::current};
-        #t15.{core::Map::[]=}(#t17.{core::MapEntry::key}, #t17.{core::MapEntry::value});
+        #t15.{core::Map::[]=}{Invariant}(#t17.{core::MapEntry::key}, #t17.{core::MapEntry::value});
       }
     }
   } =>#t15;
@@ -191,7 +191,7 @@
       core::Iterator<core::MapEntry<core::String, core::int>> :sync-for-iterator = #t19{core::Map<core::String, core::int>}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::String, core::int> #t20 = :sync-for-iterator.{core::Iterator::current};
-        #t18.{core::Map::[]=}(#t20.{core::MapEntry::key}, #t20.{core::MapEntry::value});
+        #t18.{core::Map::[]=}{Invariant}(#t20.{core::MapEntry::key}, #t20.{core::MapEntry::value});
       }
     }
   } =>#t18;
diff --git a/pkg/front_end/testcases/nnbd_mixed/infer_constraints_from_opt_in.dart.weak.expect b/pkg/front_end/testcases/nnbd_mixed/infer_constraints_from_opt_in.dart.weak.expect
index 94c1a96..e4cfa36 100644
--- a/pkg/front_end/testcases/nnbd_mixed/infer_constraints_from_opt_in.dart.weak.expect
+++ b/pkg/front_end/testcases/nnbd_mixed/infer_constraints_from_opt_in.dart.weak.expect
@@ -37,83 +37,83 @@
   core::List<Null>* local1i = <Null>[null];
   core::Set<inf::C<dynamic>*>* local2a = block {
     final core::Set<inf::C<dynamic>*>* #t1 = col::LinkedHashSet::•<inf::C<dynamic>*>();
-    #t1.{core::Set::add}(inf::field1);
-    #t1.{core::Set::add}(null);
+    #t1.{core::Set::add}{Invariant}(inf::field1);
+    #t1.{core::Set::add}{Invariant}(null);
   } =>#t1;
   core::Set<inf::C<dynamic>*>* local2b = block {
     final core::Set<inf::C<dynamic>*>* #t2 = col::LinkedHashSet::•<inf::C<dynamic>*>();
-    #t2.{core::Set::add}(inf::field2);
-    #t2.{core::Set::add}(null);
+    #t2.{core::Set::add}{Invariant}(inf::field2);
+    #t2.{core::Set::add}{Invariant}(null);
   } =>#t2;
   core::Set<inf::C<core::int*>*>* local2c = block {
     final core::Set<inf::C<core::int*>*>* #t3 = col::LinkedHashSet::•<inf::C<core::int*>*>();
-    #t3.{core::Set::add}(inf::field3);
-    #t3.{core::Set::add}(null);
+    #t3.{core::Set::add}{Invariant}(inf::field3);
+    #t3.{core::Set::add}{Invariant}(null);
   } =>#t3;
   core::Set<inf::C<core::int*>*>* local2d = block {
     final core::Set<inf::C<core::int*>*>* #t4 = col::LinkedHashSet::•<inf::C<core::int*>*>();
-    #t4.{core::Set::add}(inf::field4);
-    #t4.{core::Set::add}(null);
+    #t4.{core::Set::add}{Invariant}(inf::field4);
+    #t4.{core::Set::add}{Invariant}(null);
   } =>#t4;
   core::Set<inf::C<core::int*>*>* local2e = block {
     final core::Set<inf::C<core::int*>*>* #t5 = col::LinkedHashSet::•<inf::C<core::int*>*>();
-    #t5.{core::Set::add}(inf::field5);
-    #t5.{core::Set::add}(null);
+    #t5.{core::Set::add}{Invariant}(inf::field5);
+    #t5.{core::Set::add}{Invariant}(null);
   } =>#t5;
   core::Set<inf::C<core::int*>*>* local2f = block {
     final core::Set<inf::C<core::int*>*>* #t6 = col::LinkedHashSet::•<inf::C<core::int*>*>();
-    #t6.{core::Set::add}(inf::field6);
-    #t6.{core::Set::add}(null);
+    #t6.{core::Set::add}{Invariant}(inf::field6);
+    #t6.{core::Set::add}{Invariant}(null);
   } =>#t6;
   core::Set<core::int*>* local2g = block {
     final core::Set<core::int*>* #t7 = col::LinkedHashSet::•<core::int*>();
-    #t7.{core::Set::add}(inf::field7);
-    #t7.{core::Set::add}(null);
+    #t7.{core::Set::add}{Invariant}(inf::field7);
+    #t7.{core::Set::add}{Invariant}(null);
   } =>#t7;
   core::Set<core::int*>* local2h = block {
     final core::Set<core::int*>* #t8 = col::LinkedHashSet::•<core::int*>();
-    #t8.{core::Set::add}(inf::field8);
-    #t8.{core::Set::add}(null);
+    #t8.{core::Set::add}{Invariant}(inf::field8);
+    #t8.{core::Set::add}{Invariant}(null);
   } =>#t8;
   core::Set<inf::C<dynamic>*>* local3a = block {
     final core::Set<inf::C<dynamic>*>* #t9 = col::LinkedHashSet::•<inf::C<dynamic>*>();
-    #t9.{core::Set::add}(null);
-    #t9.{core::Set::add}(inf::field1);
+    #t9.{core::Set::add}{Invariant}(null);
+    #t9.{core::Set::add}{Invariant}(inf::field1);
   } =>#t9;
   core::Set<inf::C<dynamic>*>* local3b = block {
     final core::Set<inf::C<dynamic>*>* #t10 = col::LinkedHashSet::•<inf::C<dynamic>*>();
-    #t10.{core::Set::add}(null);
-    #t10.{core::Set::add}(inf::field2);
+    #t10.{core::Set::add}{Invariant}(null);
+    #t10.{core::Set::add}{Invariant}(inf::field2);
   } =>#t10;
   core::Set<inf::C<core::int*>*>* local3c = block {
     final core::Set<inf::C<core::int*>*>* #t11 = col::LinkedHashSet::•<inf::C<core::int*>*>();
-    #t11.{core::Set::add}(null);
-    #t11.{core::Set::add}(inf::field3);
+    #t11.{core::Set::add}{Invariant}(null);
+    #t11.{core::Set::add}{Invariant}(inf::field3);
   } =>#t11;
   core::Set<inf::C<core::int*>*>* local3d = block {
     final core::Set<inf::C<core::int*>*>* #t12 = col::LinkedHashSet::•<inf::C<core::int*>*>();
-    #t12.{core::Set::add}(null);
-    #t12.{core::Set::add}(inf::field4);
+    #t12.{core::Set::add}{Invariant}(null);
+    #t12.{core::Set::add}{Invariant}(inf::field4);
   } =>#t12;
   core::Set<inf::C<core::int*>*>* local3e = block {
     final core::Set<inf::C<core::int*>*>* #t13 = col::LinkedHashSet::•<inf::C<core::int*>*>();
-    #t13.{core::Set::add}(null);
-    #t13.{core::Set::add}(inf::field5);
+    #t13.{core::Set::add}{Invariant}(null);
+    #t13.{core::Set::add}{Invariant}(inf::field5);
   } =>#t13;
   core::Set<inf::C<core::int*>*>* local3f = block {
     final core::Set<inf::C<core::int*>*>* #t14 = col::LinkedHashSet::•<inf::C<core::int*>*>();
-    #t14.{core::Set::add}(null);
-    #t14.{core::Set::add}(inf::field6);
+    #t14.{core::Set::add}{Invariant}(null);
+    #t14.{core::Set::add}{Invariant}(inf::field6);
   } =>#t14;
   core::Set<core::int*>* local3g = block {
     final core::Set<core::int*>* #t15 = col::LinkedHashSet::•<core::int*>();
-    #t15.{core::Set::add}(null);
-    #t15.{core::Set::add}(inf::field7);
+    #t15.{core::Set::add}{Invariant}(null);
+    #t15.{core::Set::add}{Invariant}(inf::field7);
   } =>#t15;
   core::Set<core::int*>* local3h = block {
     final core::Set<core::int*>* #t16 = col::LinkedHashSet::•<core::int*>();
-    #t16.{core::Set::add}(null);
-    #t16.{core::Set::add}(inf::field8);
+    #t16.{core::Set::add}{Invariant}(null);
+    #t16.{core::Set::add}{Invariant}(inf::field8);
   } =>#t16;
 }
 
@@ -167,82 +167,82 @@
   core::List<Null> local1i = <Null>[null];
   core::Set<inf::C<dynamic>?> local2a = block {
     final core::Set<inf::C<dynamic>?> #t17 = col::LinkedHashSet::•<inf::C<dynamic>?>();
-    #t17.{core::Set::add}(inf::field1);
-    #t17.{core::Set::add}(null);
+    #t17.{core::Set::add}{Invariant}(inf::field1);
+    #t17.{core::Set::add}{Invariant}(null);
   } =>#t17;
   core::Set<inf::C<dynamic>?> local2b = block {
     final core::Set<inf::C<dynamic>?> #t18 = col::LinkedHashSet::•<inf::C<dynamic>?>();
-    #t18.{core::Set::add}(inf::field2);
-    #t18.{core::Set::add}(null);
+    #t18.{core::Set::add}{Invariant}(inf::field2);
+    #t18.{core::Set::add}{Invariant}(null);
   } =>#t18;
   core::Set<inf::C<core::int>?> local2c = block {
     final core::Set<inf::C<core::int>?> #t19 = col::LinkedHashSet::•<inf::C<core::int>?>();
-    #t19.{core::Set::add}(inf::field3);
-    #t19.{core::Set::add}(null);
+    #t19.{core::Set::add}{Invariant}(inf::field3);
+    #t19.{core::Set::add}{Invariant}(null);
   } =>#t19;
   core::Set<inf::C<core::int>?> local2d = block {
     final core::Set<inf::C<core::int>?> #t20 = col::LinkedHashSet::•<inf::C<core::int>?>();
-    #t20.{core::Set::add}(inf::field4);
-    #t20.{core::Set::add}(null);
+    #t20.{core::Set::add}{Invariant}(inf::field4);
+    #t20.{core::Set::add}{Invariant}(null);
   } =>#t20;
   core::Set<inf::C<core::int?>?> local2e = block {
     final core::Set<inf::C<core::int?>?> #t21 = col::LinkedHashSet::•<inf::C<core::int?>?>();
-    #t21.{core::Set::add}(inf::field5);
-    #t21.{core::Set::add}(null);
+    #t21.{core::Set::add}{Invariant}(inf::field5);
+    #t21.{core::Set::add}{Invariant}(null);
   } =>#t21;
   core::Set<inf::C<core::int?>?> local2f = block {
     final core::Set<inf::C<core::int?>?> #t22 = col::LinkedHashSet::•<inf::C<core::int?>?>();
-    #t22.{core::Set::add}(inf::field6);
-    #t22.{core::Set::add}(null);
+    #t22.{core::Set::add}{Invariant}(inf::field6);
+    #t22.{core::Set::add}{Invariant}(null);
   } =>#t22;
   core::Set<core::int?> local2g = block {
     final core::Set<core::int?> #t23 = col::LinkedHashSet::•<core::int?>();
-    #t23.{core::Set::add}(inf::field7);
-    #t23.{core::Set::add}(null);
+    #t23.{core::Set::add}{Invariant}(inf::field7);
+    #t23.{core::Set::add}{Invariant}(null);
   } =>#t23;
   core::Set<core::int?> local2h = block {
     final core::Set<core::int?> #t24 = col::LinkedHashSet::•<core::int?>();
-    #t24.{core::Set::add}(inf::field8);
-    #t24.{core::Set::add}(null);
+    #t24.{core::Set::add}{Invariant}(inf::field8);
+    #t24.{core::Set::add}{Invariant}(null);
   } =>#t24;
   core::Set<inf::C<dynamic>?> local3a = block {
     final core::Set<inf::C<dynamic>?> #t25 = col::LinkedHashSet::•<inf::C<dynamic>?>();
-    #t25.{core::Set::add}(null);
-    #t25.{core::Set::add}(inf::field1);
+    #t25.{core::Set::add}{Invariant}(null);
+    #t25.{core::Set::add}{Invariant}(inf::field1);
   } =>#t25;
   core::Set<inf::C<dynamic>?> local3b = block {
     final core::Set<inf::C<dynamic>?> #t26 = col::LinkedHashSet::•<inf::C<dynamic>?>();
-    #t26.{core::Set::add}(null);
-    #t26.{core::Set::add}(inf::field2);
+    #t26.{core::Set::add}{Invariant}(null);
+    #t26.{core::Set::add}{Invariant}(inf::field2);
   } =>#t26;
   core::Set<inf::C<core::int>?> local3c = block {
     final core::Set<inf::C<core::int>?> #t27 = col::LinkedHashSet::•<inf::C<core::int>?>();
-    #t27.{core::Set::add}(null);
-    #t27.{core::Set::add}(inf::field3);
+    #t27.{core::Set::add}{Invariant}(null);
+    #t27.{core::Set::add}{Invariant}(inf::field3);
   } =>#t27;
   core::Set<inf::C<core::int>?> local3d = block {
     final core::Set<inf::C<core::int>?> #t28 = col::LinkedHashSet::•<inf::C<core::int>?>();
-    #t28.{core::Set::add}(null);
-    #t28.{core::Set::add}(inf::field4);
+    #t28.{core::Set::add}{Invariant}(null);
+    #t28.{core::Set::add}{Invariant}(inf::field4);
   } =>#t28;
   core::Set<inf::C<core::int?>?> local3e = block {
     final core::Set<inf::C<core::int?>?> #t29 = col::LinkedHashSet::•<inf::C<core::int?>?>();
-    #t29.{core::Set::add}(null);
-    #t29.{core::Set::add}(inf::field5);
+    #t29.{core::Set::add}{Invariant}(null);
+    #t29.{core::Set::add}{Invariant}(inf::field5);
   } =>#t29;
   core::Set<inf::C<core::int?>?> local3f = block {
     final core::Set<inf::C<core::int?>?> #t30 = col::LinkedHashSet::•<inf::C<core::int?>?>();
-    #t30.{core::Set::add}(null);
-    #t30.{core::Set::add}(inf::field6);
+    #t30.{core::Set::add}{Invariant}(null);
+    #t30.{core::Set::add}{Invariant}(inf::field6);
   } =>#t30;
   core::Set<core::int?> local3g = block {
     final core::Set<core::int?> #t31 = col::LinkedHashSet::•<core::int?>();
-    #t31.{core::Set::add}(null);
-    #t31.{core::Set::add}(inf::field7);
+    #t31.{core::Set::add}{Invariant}(null);
+    #t31.{core::Set::add}{Invariant}(inf::field7);
   } =>#t31;
   core::Set<core::int?> local3h = block {
     final core::Set<core::int?> #t32 = col::LinkedHashSet::•<core::int?>();
-    #t32.{core::Set::add}(null);
-    #t32.{core::Set::add}(inf::field8);
+    #t32.{core::Set::add}{Invariant}(null);
+    #t32.{core::Set::add}{Invariant}(inf::field8);
   } =>#t32;
 }
diff --git a/pkg/front_end/testcases/nnbd_mixed/infer_constraints_from_opt_in.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd_mixed/infer_constraints_from_opt_in.dart.weak.transformed.expect
index 8c3ed7b..267b93e 100644
--- a/pkg/front_end/testcases/nnbd_mixed/infer_constraints_from_opt_in.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/nnbd_mixed/infer_constraints_from_opt_in.dart.weak.transformed.expect
@@ -37,83 +37,83 @@
   core::List<Null>* local1i = <Null>[null];
   core::Set<inf::C<dynamic>*>* local2a = block {
     final core::Set<inf::C<dynamic>*>* #t1 = new col::_CompactLinkedHashSet::•<inf::C<dynamic>*>();
-    #t1.{core::Set::add}(inf::field1);
-    #t1.{core::Set::add}(null);
+    #t1.{core::Set::add}{Invariant}(inf::field1);
+    #t1.{core::Set::add}{Invariant}(null);
   } =>#t1;
   core::Set<inf::C<dynamic>*>* local2b = block {
     final core::Set<inf::C<dynamic>*>* #t2 = new col::_CompactLinkedHashSet::•<inf::C<dynamic>*>();
-    #t2.{core::Set::add}(inf::field2);
-    #t2.{core::Set::add}(null);
+    #t2.{core::Set::add}{Invariant}(inf::field2);
+    #t2.{core::Set::add}{Invariant}(null);
   } =>#t2;
   core::Set<inf::C<core::int*>*>* local2c = block {
     final core::Set<inf::C<core::int*>*>* #t3 = new col::_CompactLinkedHashSet::•<inf::C<core::int*>*>();
-    #t3.{core::Set::add}(inf::field3);
-    #t3.{core::Set::add}(null);
+    #t3.{core::Set::add}{Invariant}(inf::field3);
+    #t3.{core::Set::add}{Invariant}(null);
   } =>#t3;
   core::Set<inf::C<core::int*>*>* local2d = block {
     final core::Set<inf::C<core::int*>*>* #t4 = new col::_CompactLinkedHashSet::•<inf::C<core::int*>*>();
-    #t4.{core::Set::add}(inf::field4);
-    #t4.{core::Set::add}(null);
+    #t4.{core::Set::add}{Invariant}(inf::field4);
+    #t4.{core::Set::add}{Invariant}(null);
   } =>#t4;
   core::Set<inf::C<core::int*>*>* local2e = block {
     final core::Set<inf::C<core::int*>*>* #t5 = new col::_CompactLinkedHashSet::•<inf::C<core::int*>*>();
-    #t5.{core::Set::add}(inf::field5);
-    #t5.{core::Set::add}(null);
+    #t5.{core::Set::add}{Invariant}(inf::field5);
+    #t5.{core::Set::add}{Invariant}(null);
   } =>#t5;
   core::Set<inf::C<core::int*>*>* local2f = block {
     final core::Set<inf::C<core::int*>*>* #t6 = new col::_CompactLinkedHashSet::•<inf::C<core::int*>*>();
-    #t6.{core::Set::add}(inf::field6);
-    #t6.{core::Set::add}(null);
+    #t6.{core::Set::add}{Invariant}(inf::field6);
+    #t6.{core::Set::add}{Invariant}(null);
   } =>#t6;
   core::Set<core::int*>* local2g = block {
     final core::Set<core::int*>* #t7 = new col::_CompactLinkedHashSet::•<core::int*>();
-    #t7.{core::Set::add}(inf::field7);
-    #t7.{core::Set::add}(null);
+    #t7.{core::Set::add}{Invariant}(inf::field7);
+    #t7.{core::Set::add}{Invariant}(null);
   } =>#t7;
   core::Set<core::int*>* local2h = block {
     final core::Set<core::int*>* #t8 = new col::_CompactLinkedHashSet::•<core::int*>();
-    #t8.{core::Set::add}(inf::field8);
-    #t8.{core::Set::add}(null);
+    #t8.{core::Set::add}{Invariant}(inf::field8);
+    #t8.{core::Set::add}{Invariant}(null);
   } =>#t8;
   core::Set<inf::C<dynamic>*>* local3a = block {
     final core::Set<inf::C<dynamic>*>* #t9 = new col::_CompactLinkedHashSet::•<inf::C<dynamic>*>();
-    #t9.{core::Set::add}(null);
-    #t9.{core::Set::add}(inf::field1);
+    #t9.{core::Set::add}{Invariant}(null);
+    #t9.{core::Set::add}{Invariant}(inf::field1);
   } =>#t9;
   core::Set<inf::C<dynamic>*>* local3b = block {
     final core::Set<inf::C<dynamic>*>* #t10 = new col::_CompactLinkedHashSet::•<inf::C<dynamic>*>();
-    #t10.{core::Set::add}(null);
-    #t10.{core::Set::add}(inf::field2);
+    #t10.{core::Set::add}{Invariant}(null);
+    #t10.{core::Set::add}{Invariant}(inf::field2);
   } =>#t10;
   core::Set<inf::C<core::int*>*>* local3c = block {
     final core::Set<inf::C<core::int*>*>* #t11 = new col::_CompactLinkedHashSet::•<inf::C<core::int*>*>();
-    #t11.{core::Set::add}(null);
-    #t11.{core::Set::add}(inf::field3);
+    #t11.{core::Set::add}{Invariant}(null);
+    #t11.{core::Set::add}{Invariant}(inf::field3);
   } =>#t11;
   core::Set<inf::C<core::int*>*>* local3d = block {
     final core::Set<inf::C<core::int*>*>* #t12 = new col::_CompactLinkedHashSet::•<inf::C<core::int*>*>();
-    #t12.{core::Set::add}(null);
-    #t12.{core::Set::add}(inf::field4);
+    #t12.{core::Set::add}{Invariant}(null);
+    #t12.{core::Set::add}{Invariant}(inf::field4);
   } =>#t12;
   core::Set<inf::C<core::int*>*>* local3e = block {
     final core::Set<inf::C<core::int*>*>* #t13 = new col::_CompactLinkedHashSet::•<inf::C<core::int*>*>();
-    #t13.{core::Set::add}(null);
-    #t13.{core::Set::add}(inf::field5);
+    #t13.{core::Set::add}{Invariant}(null);
+    #t13.{core::Set::add}{Invariant}(inf::field5);
   } =>#t13;
   core::Set<inf::C<core::int*>*>* local3f = block {
     final core::Set<inf::C<core::int*>*>* #t14 = new col::_CompactLinkedHashSet::•<inf::C<core::int*>*>();
-    #t14.{core::Set::add}(null);
-    #t14.{core::Set::add}(inf::field6);
+    #t14.{core::Set::add}{Invariant}(null);
+    #t14.{core::Set::add}{Invariant}(inf::field6);
   } =>#t14;
   core::Set<core::int*>* local3g = block {
     final core::Set<core::int*>* #t15 = new col::_CompactLinkedHashSet::•<core::int*>();
-    #t15.{core::Set::add}(null);
-    #t15.{core::Set::add}(inf::field7);
+    #t15.{core::Set::add}{Invariant}(null);
+    #t15.{core::Set::add}{Invariant}(inf::field7);
   } =>#t15;
   core::Set<core::int*>* local3h = block {
     final core::Set<core::int*>* #t16 = new col::_CompactLinkedHashSet::•<core::int*>();
-    #t16.{core::Set::add}(null);
-    #t16.{core::Set::add}(inf::field8);
+    #t16.{core::Set::add}{Invariant}(null);
+    #t16.{core::Set::add}{Invariant}(inf::field8);
   } =>#t16;
 }
 
@@ -167,82 +167,82 @@
   core::List<Null> local1i = <Null>[null];
   core::Set<inf::C<dynamic>?> local2a = block {
     final core::Set<inf::C<dynamic>?> #t17 = new col::_CompactLinkedHashSet::•<inf::C<dynamic>?>();
-    #t17.{core::Set::add}(inf::field1);
-    #t17.{core::Set::add}(null);
+    #t17.{core::Set::add}{Invariant}(inf::field1);
+    #t17.{core::Set::add}{Invariant}(null);
   } =>#t17;
   core::Set<inf::C<dynamic>?> local2b = block {
     final core::Set<inf::C<dynamic>?> #t18 = new col::_CompactLinkedHashSet::•<inf::C<dynamic>?>();
-    #t18.{core::Set::add}(inf::field2);
-    #t18.{core::Set::add}(null);
+    #t18.{core::Set::add}{Invariant}(inf::field2);
+    #t18.{core::Set::add}{Invariant}(null);
   } =>#t18;
   core::Set<inf::C<core::int>?> local2c = block {
     final core::Set<inf::C<core::int>?> #t19 = new col::_CompactLinkedHashSet::•<inf::C<core::int>?>();
-    #t19.{core::Set::add}(inf::field3);
-    #t19.{core::Set::add}(null);
+    #t19.{core::Set::add}{Invariant}(inf::field3);
+    #t19.{core::Set::add}{Invariant}(null);
   } =>#t19;
   core::Set<inf::C<core::int>?> local2d = block {
     final core::Set<inf::C<core::int>?> #t20 = new col::_CompactLinkedHashSet::•<inf::C<core::int>?>();
-    #t20.{core::Set::add}(inf::field4);
-    #t20.{core::Set::add}(null);
+    #t20.{core::Set::add}{Invariant}(inf::field4);
+    #t20.{core::Set::add}{Invariant}(null);
   } =>#t20;
   core::Set<inf::C<core::int?>?> local2e = block {
     final core::Set<inf::C<core::int?>?> #t21 = new col::_CompactLinkedHashSet::•<inf::C<core::int?>?>();
-    #t21.{core::Set::add}(inf::field5);
-    #t21.{core::Set::add}(null);
+    #t21.{core::Set::add}{Invariant}(inf::field5);
+    #t21.{core::Set::add}{Invariant}(null);
   } =>#t21;
   core::Set<inf::C<core::int?>?> local2f = block {
     final core::Set<inf::C<core::int?>?> #t22 = new col::_CompactLinkedHashSet::•<inf::C<core::int?>?>();
-    #t22.{core::Set::add}(inf::field6);
-    #t22.{core::Set::add}(null);
+    #t22.{core::Set::add}{Invariant}(inf::field6);
+    #t22.{core::Set::add}{Invariant}(null);
   } =>#t22;
   core::Set<core::int?> local2g = block {
     final core::Set<core::int?> #t23 = new col::_CompactLinkedHashSet::•<core::int?>();
-    #t23.{core::Set::add}(inf::field7);
-    #t23.{core::Set::add}(null);
+    #t23.{core::Set::add}{Invariant}(inf::field7);
+    #t23.{core::Set::add}{Invariant}(null);
   } =>#t23;
   core::Set<core::int?> local2h = block {
     final core::Set<core::int?> #t24 = new col::_CompactLinkedHashSet::•<core::int?>();
-    #t24.{core::Set::add}(inf::field8);
-    #t24.{core::Set::add}(null);
+    #t24.{core::Set::add}{Invariant}(inf::field8);
+    #t24.{core::Set::add}{Invariant}(null);
   } =>#t24;
   core::Set<inf::C<dynamic>?> local3a = block {
     final core::Set<inf::C<dynamic>?> #t25 = new col::_CompactLinkedHashSet::•<inf::C<dynamic>?>();
-    #t25.{core::Set::add}(null);
-    #t25.{core::Set::add}(inf::field1);
+    #t25.{core::Set::add}{Invariant}(null);
+    #t25.{core::Set::add}{Invariant}(inf::field1);
   } =>#t25;
   core::Set<inf::C<dynamic>?> local3b = block {
     final core::Set<inf::C<dynamic>?> #t26 = new col::_CompactLinkedHashSet::•<inf::C<dynamic>?>();
-    #t26.{core::Set::add}(null);
-    #t26.{core::Set::add}(inf::field2);
+    #t26.{core::Set::add}{Invariant}(null);
+    #t26.{core::Set::add}{Invariant}(inf::field2);
   } =>#t26;
   core::Set<inf::C<core::int>?> local3c = block {
     final core::Set<inf::C<core::int>?> #t27 = new col::_CompactLinkedHashSet::•<inf::C<core::int>?>();
-    #t27.{core::Set::add}(null);
-    #t27.{core::Set::add}(inf::field3);
+    #t27.{core::Set::add}{Invariant}(null);
+    #t27.{core::Set::add}{Invariant}(inf::field3);
   } =>#t27;
   core::Set<inf::C<core::int>?> local3d = block {
     final core::Set<inf::C<core::int>?> #t28 = new col::_CompactLinkedHashSet::•<inf::C<core::int>?>();
-    #t28.{core::Set::add}(null);
-    #t28.{core::Set::add}(inf::field4);
+    #t28.{core::Set::add}{Invariant}(null);
+    #t28.{core::Set::add}{Invariant}(inf::field4);
   } =>#t28;
   core::Set<inf::C<core::int?>?> local3e = block {
     final core::Set<inf::C<core::int?>?> #t29 = new col::_CompactLinkedHashSet::•<inf::C<core::int?>?>();
-    #t29.{core::Set::add}(null);
-    #t29.{core::Set::add}(inf::field5);
+    #t29.{core::Set::add}{Invariant}(null);
+    #t29.{core::Set::add}{Invariant}(inf::field5);
   } =>#t29;
   core::Set<inf::C<core::int?>?> local3f = block {
     final core::Set<inf::C<core::int?>?> #t30 = new col::_CompactLinkedHashSet::•<inf::C<core::int?>?>();
-    #t30.{core::Set::add}(null);
-    #t30.{core::Set::add}(inf::field6);
+    #t30.{core::Set::add}{Invariant}(null);
+    #t30.{core::Set::add}{Invariant}(inf::field6);
   } =>#t30;
   core::Set<core::int?> local3g = block {
     final core::Set<core::int?> #t31 = new col::_CompactLinkedHashSet::•<core::int?>();
-    #t31.{core::Set::add}(null);
-    #t31.{core::Set::add}(inf::field7);
+    #t31.{core::Set::add}{Invariant}(null);
+    #t31.{core::Set::add}{Invariant}(inf::field7);
   } =>#t31;
   core::Set<core::int?> local3h = block {
     final core::Set<core::int?> #t32 = new col::_CompactLinkedHashSet::•<core::int?>();
-    #t32.{core::Set::add}(null);
-    #t32.{core::Set::add}(inf::field8);
+    #t32.{core::Set::add}{Invariant}(null);
+    #t32.{core::Set::add}{Invariant}(inf::field8);
   } =>#t32;
 }
diff --git a/pkg/front_end/testcases/nnbd_mixed/issue42181.dart.weak.expect b/pkg/front_end/testcases/nnbd_mixed/issue42181.dart.weak.expect
index 24a30ca..076de4e 100644
--- a/pkg/front_end/testcases/nnbd_mixed/issue42181.dart.weak.expect
+++ b/pkg/front_end/testcases/nnbd_mixed/issue42181.dart.weak.expect
@@ -2,7 +2,7 @@
 //
 // Problems in library:
 //
-// pkg/front_end/testcases/nnbd_mixed/issue42181.dart:10:9: Error: A value of type 'Null' can't be assigned to a variable of type 'int Function(int)' because 'Null' is nullable and 'int Function(int)' isn't.
+// pkg/front_end/testcases/nnbd_mixed/issue42181.dart:10:9: Error: The value 'null' can't be assigned to a variable of type 'int Function(int)' because 'int Function(int)' is not nullable.
 //   F f = null; // Static error
 //         ^
 //
@@ -14,7 +14,7 @@
 static method f1(core::int x) → core::int?
   return x;
 static method test() → void {
-  (core::int*) → core::int* f = let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd_mixed/issue42181.dart:10:9: Error: A value of type 'Null' can't be assigned to a variable of type 'int Function(int)' because 'Null' is nullable and 'int Function(int)' isn't.
+  (core::int*) → core::int* f = let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd_mixed/issue42181.dart:10:9: Error: The value 'null' can't be assigned to a variable of type 'int Function(int)' because 'int Function(int)' is not nullable.
   F f = null; // Static error
         ^" in null as{TypeError,ForNonNullableByDefault} (core::int*) → core::int*;
   f = #C1;
diff --git a/pkg/front_end/testcases/nnbd_mixed/issue42181.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd_mixed/issue42181.dart.weak.transformed.expect
index 8be5681..4193805 100644
--- a/pkg/front_end/testcases/nnbd_mixed/issue42181.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/nnbd_mixed/issue42181.dart.weak.transformed.expect
@@ -2,7 +2,7 @@
 //
 // Problems in library:
 //
-// pkg/front_end/testcases/nnbd_mixed/issue42181.dart:10:9: Error: A value of type 'Null' can't be assigned to a variable of type 'int Function(int)' because 'Null' is nullable and 'int Function(int)' isn't.
+// pkg/front_end/testcases/nnbd_mixed/issue42181.dart:10:9: Error: The value 'null' can't be assigned to a variable of type 'int Function(int)' because 'int Function(int)' is not nullable.
 //   F f = null; // Static error
 //         ^
 //
@@ -14,7 +14,7 @@
 static method f1(core::int x) → core::int?
   return x;
 static method test() → void {
-  (core::int*) → core::int* f = let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd_mixed/issue42181.dart:10:9: Error: A value of type 'Null' can't be assigned to a variable of type 'int Function(int)' because 'Null' is nullable and 'int Function(int)' isn't.
+  (core::int*) → core::int* f = let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nnbd_mixed/issue42181.dart:10:9: Error: The value 'null' can't be assigned to a variable of type 'int Function(int)' because 'int Function(int)' is not nullable.
   F f = null; // Static error
         ^" in null;
   f = #C1;
diff --git a/pkg/front_end/testcases/nnbd_mixed/regress_null_aware.dart.weak.expect b/pkg/front_end/testcases/nnbd_mixed/regress_null_aware.dart.weak.expect
index b171e0f..4ca139e 100644
--- a/pkg/front_end/testcases/nnbd_mixed/regress_null_aware.dart.weak.expect
+++ b/pkg/front_end/testcases/nnbd_mixed/regress_null_aware.dart.weak.expect
@@ -11,11 +11,11 @@
   method method(core::String* node, core::Set<core::String*>* set) → core::List<core::String*>*
     return set.{core::Set::add}(node) ?{core::List<core::String*>*} block {
       final core::List<core::String*>* #t1 = <core::String*>[];
-      #t1.{core::List::add}(node);
+      #t1.{core::List::add}{Invariant}(node);
       final core::Iterable<core::String*>* #t2 = let final core::Iterable<core::String*>* #t3 = let final core::Set<core::String*>* #t4 = this.{self::Class::map}.{core::Map::[]}(node) in #t4.{core::Object::==}(null) ?{core::Iterable<core::String*>*} null : #t4.{core::Iterable::expand}<core::String*>((core::String* node) → core::List<core::String*>* => this.{self::Class::method}(node, set)) in #t3.{core::Object::==}(null) ?{core::List<core::String*>*} null : #t3.{core::Iterable::toList}();
       if(!#t2.{core::Object::==}(null))
         for (final core::String* #t5 in #t2)
-          #t1.{core::List::add}(#t5);
+          #t1.{core::List::add}{Invariant}(#t5);
     } =>#t1 : <core::String*>[];
   abstract member-signature get _identityHashCode() → core::int*; -> core::Object::_identityHashCode
   abstract member-signature method _instanceOf(dynamic instantiatorTypeArguments, dynamic functionTypeArguments, dynamic type) → core::bool*; -> core::Object::_instanceOf
diff --git a/pkg/front_end/testcases/nnbd_mixed/regress_null_aware.dart.weak.transformed.expect b/pkg/front_end/testcases/nnbd_mixed/regress_null_aware.dart.weak.transformed.expect
index 5dbea1b..32474f7 100644
--- a/pkg/front_end/testcases/nnbd_mixed/regress_null_aware.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/nnbd_mixed/regress_null_aware.dart.weak.transformed.expect
@@ -11,13 +11,13 @@
   method method(core::String* node, core::Set<core::String*>* set) → core::List<core::String*>*
     return set.{core::Set::add}(node) ?{core::List<core::String*>*} block {
       final core::List<core::String*>* #t1 = <core::String*>[];
-      #t1.{core::List::add}(node);
+      #t1.{core::List::add}{Invariant}(node);
       final core::Iterable<core::String*>* #t2 = let final core::Iterable<core::String*>* #t3 = let final core::Set<core::String*>* #t4 = this.{self::Class::map}.{core::Map::[]}(node) in #t4.{core::Object::==}(null) ?{core::Iterable<core::String*>*} null : #t4.{core::Iterable::expand}<core::String*>((core::String* node) → core::List<core::String*>* => this.{self::Class::method}(node, set)) in #t3.{core::Object::==}(null) ?{core::List<core::String*>*} null : #t3.{core::Iterable::toList}();
       if(!#t2.{core::Object::==}(null)) {
         core::Iterator<core::String*>* :sync-for-iterator = #t2.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::String* #t5 = :sync-for-iterator.{core::Iterator::current};
-          #t1.{core::List::add}(#t5);
+          #t1.{core::List::add}{Invariant}(#t5);
         }
       }
     } =>#t1 : <core::String*>[];
diff --git a/pkg/front_end/testcases/nonfunction_type_aliases/issue41501.dart.weak.expect b/pkg/front_end/testcases/nonfunction_type_aliases/issue41501.dart.weak.expect
index 4cacf98..6d116f9 100644
--- a/pkg/front_end/testcases/nonfunction_type_aliases/issue41501.dart.weak.expect
+++ b/pkg/front_end/testcases/nonfunction_type_aliases/issue41501.dart.weak.expect
@@ -2,12 +2,12 @@
 //
 // Problems in library:
 //
-// pkg/front_end/testcases/nonfunction_type_aliases/issue41501.dart:13:42: Error: A value of type 'Null' can't be assigned to a variable of type 'FutureOr<A>' because 'Null' is nullable and 'FutureOr<A>' isn't.
+// pkg/front_end/testcases/nonfunction_type_aliases/issue41501.dart:13:42: Error: The value 'null' can't be assigned to a variable of type 'FutureOr<A>' because 'FutureOr<A>' is not nullable.
 //  - 'A' is from 'pkg/front_end/testcases/nonfunction_type_aliases/issue41501_lib.dart'.
 //   FutureOr<AAlias> foLegacyNonNullable = null; // error
 //                                          ^
 //
-// pkg/front_end/testcases/nonfunction_type_aliases/issue41501.dart:15:47: Error: A value of type 'Null' can't be assigned to a variable of type 'FutureOr<A>' because 'Null' is nullable and 'FutureOr<A>' isn't.
+// pkg/front_end/testcases/nonfunction_type_aliases/issue41501.dart:15:47: Error: The value 'null' can't be assigned to a variable of type 'FutureOr<A>' because 'FutureOr<A>' is not nullable.
 //  - 'A' is from 'pkg/front_end/testcases/nonfunction_type_aliases/issue41501_lib.dart'.
 //   FutureOr<AAliasNonNullable> foNonNullable = null; // error
 //                                               ^
@@ -21,12 +21,12 @@
 typedef AAliasNonNullable = opt::A;
 typedef AAliasNullable = opt::A?;
 static method test() → dynamic {
-  FutureOr<opt::A>foLegacyNonNullable = let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nonfunction_type_aliases/issue41501.dart:13:42: Error: A value of type 'Null' can't be assigned to a variable of type 'FutureOr<A>' because 'Null' is nullable and 'FutureOr<A>' isn't.
+  FutureOr<opt::A>foLegacyNonNullable = let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nonfunction_type_aliases/issue41501.dart:13:42: Error: The value 'null' can't be assigned to a variable of type 'FutureOr<A>' because 'FutureOr<A>' is not nullable.
  - 'A' is from 'pkg/front_end/testcases/nonfunction_type_aliases/issue41501_lib.dart'.
   FutureOr<AAlias> foLegacyNonNullable = null; // error
                                          ^" in null as{TypeError,ForNonNullableByDefault} FutureOr<opt::A>;
   FutureOr<opt::A?>foLegacyNullable = null;
-  FutureOr<opt::A>foNonNullable = let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nonfunction_type_aliases/issue41501.dart:15:47: Error: A value of type 'Null' can't be assigned to a variable of type 'FutureOr<A>' because 'Null' is nullable and 'FutureOr<A>' isn't.
+  FutureOr<opt::A>foNonNullable = let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nonfunction_type_aliases/issue41501.dart:15:47: Error: The value 'null' can't be assigned to a variable of type 'FutureOr<A>' because 'FutureOr<A>' is not nullable.
  - 'A' is from 'pkg/front_end/testcases/nonfunction_type_aliases/issue41501_lib.dart'.
   FutureOr<AAliasNonNullable> foNonNullable = null; // error
                                               ^" in null as{TypeError,ForNonNullableByDefault} FutureOr<opt::A>;
diff --git a/pkg/front_end/testcases/nonfunction_type_aliases/issue41501.dart.weak.transformed.expect b/pkg/front_end/testcases/nonfunction_type_aliases/issue41501.dart.weak.transformed.expect
index 704fde7..5d63d6a 100644
--- a/pkg/front_end/testcases/nonfunction_type_aliases/issue41501.dart.weak.transformed.expect
+++ b/pkg/front_end/testcases/nonfunction_type_aliases/issue41501.dart.weak.transformed.expect
@@ -2,12 +2,12 @@
 //
 // Problems in library:
 //
-// pkg/front_end/testcases/nonfunction_type_aliases/issue41501.dart:13:42: Error: A value of type 'Null' can't be assigned to a variable of type 'FutureOr<A>' because 'Null' is nullable and 'FutureOr<A>' isn't.
+// pkg/front_end/testcases/nonfunction_type_aliases/issue41501.dart:13:42: Error: The value 'null' can't be assigned to a variable of type 'FutureOr<A>' because 'FutureOr<A>' is not nullable.
 //  - 'A' is from 'pkg/front_end/testcases/nonfunction_type_aliases/issue41501_lib.dart'.
 //   FutureOr<AAlias> foLegacyNonNullable = null; // error
 //                                          ^
 //
-// pkg/front_end/testcases/nonfunction_type_aliases/issue41501.dart:15:47: Error: A value of type 'Null' can't be assigned to a variable of type 'FutureOr<A>' because 'Null' is nullable and 'FutureOr<A>' isn't.
+// pkg/front_end/testcases/nonfunction_type_aliases/issue41501.dart:15:47: Error: The value 'null' can't be assigned to a variable of type 'FutureOr<A>' because 'FutureOr<A>' is not nullable.
 //  - 'A' is from 'pkg/front_end/testcases/nonfunction_type_aliases/issue41501_lib.dart'.
 //   FutureOr<AAliasNonNullable> foNonNullable = null; // error
 //                                               ^
@@ -21,12 +21,12 @@
 typedef AAliasNonNullable = opt::A;
 typedef AAliasNullable = opt::A?;
 static method test() → dynamic {
-  FutureOr<opt::A>foLegacyNonNullable = let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nonfunction_type_aliases/issue41501.dart:13:42: Error: A value of type 'Null' can't be assigned to a variable of type 'FutureOr<A>' because 'Null' is nullable and 'FutureOr<A>' isn't.
+  FutureOr<opt::A>foLegacyNonNullable = let final<BottomType> #t1 = invalid-expression "pkg/front_end/testcases/nonfunction_type_aliases/issue41501.dart:13:42: Error: The value 'null' can't be assigned to a variable of type 'FutureOr<A>' because 'FutureOr<A>' is not nullable.
  - 'A' is from 'pkg/front_end/testcases/nonfunction_type_aliases/issue41501_lib.dart'.
   FutureOr<AAlias> foLegacyNonNullable = null; // error
                                          ^" in null;
   FutureOr<opt::A?>foLegacyNullable = null;
-  FutureOr<opt::A>foNonNullable = let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nonfunction_type_aliases/issue41501.dart:15:47: Error: A value of type 'Null' can't be assigned to a variable of type 'FutureOr<A>' because 'Null' is nullable and 'FutureOr<A>' isn't.
+  FutureOr<opt::A>foNonNullable = let final<BottomType> #t2 = invalid-expression "pkg/front_end/testcases/nonfunction_type_aliases/issue41501.dart:15:47: Error: The value 'null' can't be assigned to a variable of type 'FutureOr<A>' because 'FutureOr<A>' is not nullable.
  - 'A' is from 'pkg/front_end/testcases/nonfunction_type_aliases/issue41501_lib.dart'.
   FutureOr<AAliasNonNullable> foNonNullable = null; // error
                                               ^" in null;
diff --git a/pkg/front_end/testcases/regress/issue_42423.dart.strong.expect b/pkg/front_end/testcases/regress/issue_42423.dart.strong.expect
index 4f27b66..f462ef4 100644
--- a/pkg/front_end/testcases/regress/issue_42423.dart.strong.expect
+++ b/pkg/front_end/testcases/regress/issue_42423.dart.strong.expect
@@ -13,7 +13,7 @@
     if(!#t2.{core::Object::==}(null))
       for (final dynamic #t3 in #t2) {
         final core::int* #t4 = #t3 as{TypeError} core::int*;
-        #t1.{core::Set::add}(#t4);
+        #t1.{core::Set::add}{Invariant}(#t4);
       }
   } =>#t1;
 }
@@ -24,7 +24,7 @@
     if(!#t6.{core::Object::==}(null))
       for (final dynamic #t7 in #t6) {
         final core::int* #t8 = #t7 as{TypeError} core::int*;
-        #t5.{core::List::add}(#t8);
+        #t5.{core::List::add}{Invariant}(#t8);
       }
   } =>#t5;
 }
@@ -36,7 +36,7 @@
       for (final core::MapEntry<dynamic, dynamic>* #t11 in #t10.{core::Map::entries}) {
         final core::int* #t12 = #t11.{core::MapEntry::key} as{TypeError} core::int*;
         final core::int* #t13 = #t11.{core::MapEntry::value} as{TypeError} core::int*;
-        #t9.{core::Map::[]=}(#t12, #t13);
+        #t9.{core::Map::[]=}{Invariant}(#t12, #t13);
       }
   } =>#t9;
 }
diff --git a/pkg/front_end/testcases/regress/issue_42423.dart.strong.transformed.expect b/pkg/front_end/testcases/regress/issue_42423.dart.strong.transformed.expect
index c5501c9..5913720 100644
--- a/pkg/front_end/testcases/regress/issue_42423.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/regress/issue_42423.dart.strong.transformed.expect
@@ -16,7 +16,7 @@
         final dynamic #t3 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int* #t4 = #t3 as{TypeError} core::int*;
-          #t1.{core::Set::add}(#t4);
+          #t1.{core::Set::add}{Invariant}(#t4);
         }
       }
     }
@@ -32,7 +32,7 @@
         final dynamic #t7 = :sync-for-iterator.{core::Iterator::current};
         {
           final core::int* #t8 = #t7 as{TypeError} core::int*;
-          #t5.{core::List::add}(#t8);
+          #t5.{core::List::add}{Invariant}(#t8);
         }
       }
     }
@@ -49,7 +49,7 @@
         {
           final core::int* #t12 = #t11.{core::MapEntry::key} as{TypeError} core::int*;
           final core::int* #t13 = #t11.{core::MapEntry::value} as{TypeError} core::int*;
-          #t9.{core::Map::[]=}(#t12, #t13);
+          #t9.{core::Map::[]=}{Invariant}(#t12, #t13);
         }
       }
     }
diff --git a/pkg/front_end/testcases/unified_collections/invariance.dart b/pkg/front_end/testcases/unified_collections/invariance.dart
new file mode 100644
index 0000000..a22d3d3
--- /dev/null
+++ b/pkg/front_end/testcases/unified_collections/invariance.dart
@@ -0,0 +1,28 @@
+// Copyright (c) 2020, the Dart project authors.  Please see the AUTHORS file
+// for details. All rights reserved. Use of this source code is governed by a
+// BSD-style license that can be found in the LICENSE file.
+
+// @dart=2.9
+
+main() {
+  var list1 = <int>[0];
+  var list2 = <num>[0];
+  dynamic list3 = <int>[0];
+  var list = <int>[0, ...list1, ...list2, ...list3, if (true) 2];
+
+  var set1 = <int>{0};
+  var set2 = <num>{0};
+  dynamic set3 = <int>{0};
+  var set = <int>{0, ...set1, ...set2, ...set3, if (true) 2};
+
+  var map1 = <int, String>{0: 'foo'};
+  var map2 = <num, Object>{0: 'bar'};
+  dynamic map3 = <int, String>{0: 'baz'};
+  var map = <int, String>{
+    0: 'foo',
+    ...map1,
+    ...map2,
+    ...map3,
+    if (true) 2: 'baz'
+  };
+}
diff --git a/pkg/front_end/testcases/unified_collections/invariance.dart.outline.expect b/pkg/front_end/testcases/unified_collections/invariance.dart.outline.expect
new file mode 100644
index 0000000..6a28c0d
--- /dev/null
+++ b/pkg/front_end/testcases/unified_collections/invariance.dart.outline.expect
@@ -0,0 +1,5 @@
+library;
+import self as self;
+
+static method main() → dynamic
+  ;
diff --git a/pkg/front_end/testcases/unified_collections/invariance.dart.strong.expect b/pkg/front_end/testcases/unified_collections/invariance.dart.strong.expect
new file mode 100644
index 0000000..ebbf96d
--- /dev/null
+++ b/pkg/front_end/testcases/unified_collections/invariance.dart.strong.expect
@@ -0,0 +1,75 @@
+library;
+import self as self;
+import "dart:core" as core;
+import "dart:collection" as col;
+
+static method main() → dynamic {
+  core::List<core::int*>* list1 = <core::int*>[0];
+  core::List<core::num*>* list2 = <core::num*>[0];
+  dynamic list3 = <core::int*>[0];
+  core::List<core::int*>* list = block {
+    final core::List<core::int*>* #t1 = <core::int*>[];
+    #t1.{core::List::add}{Invariant}(0);
+    for (final core::int* #t2 in list1)
+      #t1.{core::List::add}{Invariant}(#t2);
+    for (final dynamic #t3 in list2) {
+      final core::int* #t4 = #t3 as{TypeError} core::int*;
+      #t1.{core::List::add}{Invariant}(#t4);
+    }
+    for (final dynamic #t5 in list3 as{TypeError,ForDynamic} core::Iterable<dynamic>*) {
+      final core::int* #t6 = #t5 as{TypeError} core::int*;
+      #t1.{core::List::add}{Invariant}(#t6);
+    }
+    if(true)
+      #t1.{core::List::add}{Invariant}(2);
+  } =>#t1;
+  core::Set<core::int*>* set1 = block {
+    final core::Set<core::int*>* #t7 = col::LinkedHashSet::•<core::int*>();
+    #t7.{core::Set::add}{Invariant}(0);
+  } =>#t7;
+  core::Set<core::num*>* set2 = block {
+    final core::Set<core::num*>* #t8 = col::LinkedHashSet::•<core::num*>();
+    #t8.{core::Set::add}{Invariant}(0);
+  } =>#t8;
+  dynamic set3 = block {
+    final core::Set<core::int*>* #t9 = col::LinkedHashSet::•<core::int*>();
+    #t9.{core::Set::add}{Invariant}(0);
+  } =>#t9;
+  core::Set<core::int*>* set = block {
+    final core::Set<core::int*>* #t10 = col::LinkedHashSet::•<core::int*>();
+    #t10.{core::Set::add}{Invariant}(0);
+    for (final core::int* #t11 in set1)
+      #t10.{core::Set::add}{Invariant}(#t11);
+    for (final dynamic #t12 in set2) {
+      final core::int* #t13 = #t12 as{TypeError} core::int*;
+      #t10.{core::Set::add}{Invariant}(#t13);
+    }
+    for (final dynamic #t14 in set3 as{TypeError,ForDynamic} core::Iterable<dynamic>*) {
+      final core::int* #t15 = #t14 as{TypeError} core::int*;
+      #t10.{core::Set::add}{Invariant}(#t15);
+    }
+    if(true)
+      #t10.{core::Set::add}{Invariant}(2);
+  } =>#t10;
+  core::Map<core::int*, core::String*>* map1 = <core::int*, core::String*>{0: "foo"};
+  core::Map<core::num*, core::Object*>* map2 = <core::num*, core::Object*>{0: "bar"};
+  dynamic map3 = <core::int*, core::String*>{0: "baz"};
+  core::Map<core::int*, core::String*>* map = block {
+    final core::Map<core::int*, core::String*>* #t16 = <core::int*, core::String*>{};
+    #t16.{core::Map::[]=}{Invariant}(0, "foo");
+    for (final core::MapEntry<core::int*, core::String*>* #t17 in map1.{core::Map::entries})
+      #t16.{core::Map::[]=}{Invariant}(#t17.{core::MapEntry::key}, #t17.{core::MapEntry::value});
+    for (final core::MapEntry<dynamic, dynamic>* #t18 in map2.{core::Map::entries}) {
+      final core::int* #t19 = #t18.{core::MapEntry::key} as{TypeError} core::int*;
+      final core::String* #t20 = #t18.{core::MapEntry::value} as{TypeError} core::String*;
+      #t16.{core::Map::[]=}{Invariant}(#t19, #t20);
+    }
+    for (final core::MapEntry<dynamic, dynamic>* #t21 in (map3 as{TypeError,ForDynamic} core::Map<dynamic, dynamic>*).{core::Map::entries}) {
+      final core::int* #t22 = #t21.{core::MapEntry::key} as{TypeError} core::int*;
+      final core::String* #t23 = #t21.{core::MapEntry::value} as{TypeError} core::String*;
+      #t16.{core::Map::[]=}{Invariant}(#t22, #t23);
+    }
+    if(true)
+      #t16.{core::Map::[]=}{Invariant}(2, "baz");
+  } =>#t16;
+}
diff --git a/pkg/front_end/testcases/unified_collections/invariance.dart.strong.transformed.expect b/pkg/front_end/testcases/unified_collections/invariance.dart.strong.transformed.expect
new file mode 100644
index 0000000..a1ce6d8
--- /dev/null
+++ b/pkg/front_end/testcases/unified_collections/invariance.dart.strong.transformed.expect
@@ -0,0 +1,126 @@
+library;
+import self as self;
+import "dart:core" as core;
+import "dart:collection" as col;
+
+static method main() → dynamic {
+  core::List<core::int*>* list1 = <core::int*>[0];
+  core::List<core::num*>* list2 = <core::num*>[0];
+  dynamic list3 = <core::int*>[0];
+  core::List<core::int*>* list = block {
+    final core::List<core::int*>* #t1 = <core::int*>[];
+    #t1.{core::List::add}{Invariant}(0);
+    {
+      core::Iterator<core::int*>* :sync-for-iterator = list1.{core::Iterable::iterator};
+      for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
+        final core::int* #t2 = :sync-for-iterator.{core::Iterator::current};
+        #t1.{core::List::add}{Invariant}(#t2);
+      }
+    }
+    {
+      core::Iterator<core::num*>* :sync-for-iterator = list2.{core::Iterable::iterator};
+      for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
+        final dynamic #t3 = :sync-for-iterator.{core::Iterator::current};
+        {
+          final core::int* #t4 = #t3 as{TypeError} core::int*;
+          #t1.{core::List::add}{Invariant}(#t4);
+        }
+      }
+    }
+    {
+      core::Iterator<dynamic>* :sync-for-iterator = (list3 as{TypeError,ForDynamic} core::Iterable<dynamic>*).{core::Iterable::iterator};
+      for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
+        final dynamic #t5 = :sync-for-iterator.{core::Iterator::current};
+        {
+          final core::int* #t6 = #t5 as{TypeError} core::int*;
+          #t1.{core::List::add}{Invariant}(#t6);
+        }
+      }
+    }
+    if(true)
+      #t1.{core::List::add}{Invariant}(2);
+  } =>#t1;
+  core::Set<core::int*>* set1 = block {
+    final core::Set<core::int*>* #t7 = new col::_CompactLinkedHashSet::•<core::int*>();
+    #t7.{core::Set::add}{Invariant}(0);
+  } =>#t7;
+  core::Set<core::num*>* set2 = block {
+    final core::Set<core::num*>* #t8 = new col::_CompactLinkedHashSet::•<core::num*>();
+    #t8.{core::Set::add}{Invariant}(0);
+  } =>#t8;
+  dynamic set3 = block {
+    final core::Set<core::int*>* #t9 = new col::_CompactLinkedHashSet::•<core::int*>();
+    #t9.{core::Set::add}{Invariant}(0);
+  } =>#t9;
+  core::Set<core::int*>* set = block {
+    final core::Set<core::int*>* #t10 = new col::_CompactLinkedHashSet::•<core::int*>();
+    #t10.{core::Set::add}{Invariant}(0);
+    {
+      core::Iterator<core::int*>* :sync-for-iterator = set1.{core::Iterable::iterator};
+      for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
+        final core::int* #t11 = :sync-for-iterator.{core::Iterator::current};
+        #t10.{core::Set::add}{Invariant}(#t11);
+      }
+    }
+    {
+      core::Iterator<core::num*>* :sync-for-iterator = set2.{core::Iterable::iterator};
+      for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
+        final dynamic #t12 = :sync-for-iterator.{core::Iterator::current};
+        {
+          final core::int* #t13 = #t12 as{TypeError} core::int*;
+          #t10.{core::Set::add}{Invariant}(#t13);
+        }
+      }
+    }
+    {
+      core::Iterator<dynamic>* :sync-for-iterator = (set3 as{TypeError,ForDynamic} core::Iterable<dynamic>*).{core::Iterable::iterator};
+      for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
+        final dynamic #t14 = :sync-for-iterator.{core::Iterator::current};
+        {
+          final core::int* #t15 = #t14 as{TypeError} core::int*;
+          #t10.{core::Set::add}{Invariant}(#t15);
+        }
+      }
+    }
+    if(true)
+      #t10.{core::Set::add}{Invariant}(2);
+  } =>#t10;
+  core::Map<core::int*, core::String*>* map1 = <core::int*, core::String*>{0: "foo"};
+  core::Map<core::num*, core::Object*>* map2 = <core::num*, core::Object*>{0: "bar"};
+  dynamic map3 = <core::int*, core::String*>{0: "baz"};
+  core::Map<core::int*, core::String*>* map = block {
+    final core::Map<core::int*, core::String*>* #t16 = <core::int*, core::String*>{};
+    #t16.{core::Map::[]=}{Invariant}(0, "foo");
+    {
+      core::Iterator<core::MapEntry<core::int*, core::String*>>* :sync-for-iterator = map1.{core::Map::entries}.{core::Iterable::iterator};
+      for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
+        final core::MapEntry<core::int*, core::String*>* #t17 = :sync-for-iterator.{core::Iterator::current};
+        #t16.{core::Map::[]=}{Invariant}(#t17.{core::MapEntry::key}, #t17.{core::MapEntry::value});
+      }
+    }
+    {
+      core::Iterator<core::MapEntry<core::num*, core::Object*>>* :sync-for-iterator = map2.{core::Map::entries}.{core::Iterable::iterator};
+      for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
+        final core::MapEntry<dynamic, dynamic>* #t18 = :sync-for-iterator.{core::Iterator::current};
+        {
+          final core::int* #t19 = #t18.{core::MapEntry::key} as{TypeError} core::int*;
+          final core::String* #t20 = #t18.{core::MapEntry::value} as{TypeError} core::String*;
+          #t16.{core::Map::[]=}{Invariant}(#t19, #t20);
+        }
+      }
+    }
+    {
+      core::Iterator<core::MapEntry<dynamic, dynamic>>* :sync-for-iterator = (map3 as{TypeError,ForDynamic} core::Map<dynamic, dynamic>*).{core::Map::entries}.{core::Iterable::iterator};
+      for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
+        final core::MapEntry<dynamic, dynamic>* #t21 = :sync-for-iterator.{core::Iterator::current};
+        {
+          final core::int* #t22 = #t21.{core::MapEntry::key} as{TypeError} core::int*;
+          final core::String* #t23 = #t21.{core::MapEntry::value} as{TypeError} core::String*;
+          #t16.{core::Map::[]=}{Invariant}(#t22, #t23);
+        }
+      }
+    }
+    if(true)
+      #t16.{core::Map::[]=}{Invariant}(2, "baz");
+  } =>#t16;
+}
diff --git a/pkg/front_end/testcases/unified_collections/invariance.dart.textual_outline.expect b/pkg/front_end/testcases/unified_collections/invariance.dart.textual_outline.expect
new file mode 100644
index 0000000..7c126a2
--- /dev/null
+++ b/pkg/front_end/testcases/unified_collections/invariance.dart.textual_outline.expect
@@ -0,0 +1,2 @@
+// @dart = 2.9
+main() {}
diff --git a/pkg/front_end/testcases/unified_collections/invariance.dart.textual_outline_modelled.expect b/pkg/front_end/testcases/unified_collections/invariance.dart.textual_outline_modelled.expect
new file mode 100644
index 0000000..7c126a2
--- /dev/null
+++ b/pkg/front_end/testcases/unified_collections/invariance.dart.textual_outline_modelled.expect
@@ -0,0 +1,2 @@
+// @dart = 2.9
+main() {}
diff --git a/pkg/front_end/testcases/unified_collections/mixed_entries.dart.strong.expect b/pkg/front_end/testcases/unified_collections/mixed_entries.dart.strong.expect
index 9a51fe1..1194246 100644
--- a/pkg/front_end/testcases/unified_collections/mixed_entries.dart.strong.expect
+++ b/pkg/front_end/testcases/unified_collections/mixed_entries.dart.strong.expect
@@ -47,104 +47,104 @@
 static field core::Map<dynamic, dynamic>* map1 = block {
   final core::Map<dynamic, dynamic>* #t1 = <dynamic, dynamic>{};
   if(self::b)
-    #t1.{core::Map::[]=}(0, 1);
+    #t1.{core::Map::[]=}{Invariant}(0, 1);
   else
     for (final core::MapEntry<dynamic, dynamic>* #t2 in self::map0.{core::Map::entries})
-      #t1.{core::Map::[]=}(#t2.{core::MapEntry::key}, #t2.{core::MapEntry::value});
+      #t1.{core::Map::[]=}{Invariant}(#t2.{core::MapEntry::key}, #t2.{core::MapEntry::value});
 } =>#t1;
 static field core::Map<dynamic, dynamic>* map2 = block {
   final core::Map<dynamic, dynamic>* #t3 = <dynamic, dynamic>{};
   if(self::b)
     for (final core::MapEntry<dynamic, dynamic>* #t4 in self::map0.{core::Map::entries})
-      #t3.{core::Map::[]=}(#t4.{core::MapEntry::key}, #t4.{core::MapEntry::value});
+      #t3.{core::Map::[]=}{Invariant}(#t4.{core::MapEntry::key}, #t4.{core::MapEntry::value});
   else
-    #t3.{core::Map::[]=}(0, 1);
+    #t3.{core::Map::[]=}{Invariant}(0, 1);
 } =>#t3;
 static field core::Map<dynamic, dynamic>* map3 = block {
   final core::Map<dynamic, dynamic>* #t5 = <dynamic, dynamic>{};
   if(self::b)
     for (final core::MapEntry<dynamic, dynamic>* #t6 in self::map0.{core::Map::entries})
-      #t5.{core::Map::[]=}(#t6.{core::MapEntry::key}, #t6.{core::MapEntry::value});
+      #t5.{core::Map::[]=}{Invariant}(#t6.{core::MapEntry::key}, #t6.{core::MapEntry::value});
   else
     for (final core::MapEntry<dynamic, dynamic>* #t7 in self::map0.{core::Map::entries})
-      #t5.{core::Map::[]=}(#t7.{core::MapEntry::key}, #t7.{core::MapEntry::value});
+      #t5.{core::Map::[]=}{Invariant}(#t7.{core::MapEntry::key}, #t7.{core::MapEntry::value});
 } =>#t5;
 static field core::Map<dynamic, core::int*>* map4 = block {
   final core::Map<dynamic, core::int*>* #t8 = <dynamic, core::int*>{};
   if(self::b)
-    #t8.{core::Map::[]=}(0, 1);
+    #t8.{core::Map::[]=}{Invariant}(0, 1);
   else
     for (dynamic a in self::list)
-      #t8.{core::Map::[]=}(a, 1);
+      #t8.{core::Map::[]=}{Invariant}(a, 1);
 } =>#t8;
 static field core::Map<dynamic, core::int*>* map5 = block {
   final core::Map<dynamic, core::int*>* #t9 = <dynamic, core::int*>{};
   if(self::b)
     for (dynamic a in self::list)
-      #t9.{core::Map::[]=}(a, 1);
+      #t9.{core::Map::[]=}{Invariant}(a, 1);
   else
-    #t9.{core::Map::[]=}(0, 1);
+    #t9.{core::Map::[]=}{Invariant}(0, 1);
 } =>#t9;
 static field core::Map<dynamic, core::int*>* map6 = block {
   final core::Map<dynamic, core::int*>* #t10 = <dynamic, core::int*>{};
   if(self::b)
-    #t10.{core::Map::[]=}(0, 1);
+    #t10.{core::Map::[]=}{Invariant}(0, 1);
   else
     for (dynamic a in self::list)
       for (final core::MapEntry<dynamic, core::int*>* #t11 in <dynamic, core::int*>{a: 1}.{core::Map::entries})
-        #t10.{core::Map::[]=}(#t11.{core::MapEntry::key}, #t11.{core::MapEntry::value});
+        #t10.{core::Map::[]=}{Invariant}(#t11.{core::MapEntry::key}, #t11.{core::MapEntry::value});
 } =>#t10;
 static field core::Map<dynamic, core::int*>* map7 = block {
   final core::Map<dynamic, core::int*>* #t12 = <dynamic, core::int*>{};
   if(self::b)
     for (dynamic a in self::list)
       for (final core::MapEntry<dynamic, core::int*>* #t13 in <dynamic, core::int*>{a: 1}.{core::Map::entries})
-        #t12.{core::Map::[]=}(#t13.{core::MapEntry::key}, #t13.{core::MapEntry::value});
+        #t12.{core::Map::[]=}{Invariant}(#t13.{core::MapEntry::key}, #t13.{core::MapEntry::value});
   else
-    #t12.{core::Map::[]=}(0, 1);
+    #t12.{core::Map::[]=}{Invariant}(0, 1);
 } =>#t12;
 static field core::Map<dynamic, core::int*>* map8 = block {
   final core::Map<dynamic, core::int*>* #t14 = <dynamic, core::int*>{};
   if(self::b)
-    #t14.{core::Map::[]=}(0, 1);
+    #t14.{core::Map::[]=}{Invariant}(0, 1);
   else
     for (core::int* i = 0; i.{core::num::<}(self::list.{core::List::length}); i = i.{core::num::+}(1))
-      #t14.{core::Map::[]=}(self::list.{core::List::[]}(i), 1);
+      #t14.{core::Map::[]=}{Invariant}(self::list.{core::List::[]}(i), 1);
 } =>#t14;
 static field core::Map<dynamic, core::int*>* map9 = block {
   final core::Map<dynamic, core::int*>* #t15 = <dynamic, core::int*>{};
   if(self::b)
     for (core::int* i = 0; i.{core::num::<}(self::list.{core::List::length}); i = i.{core::num::+}(1))
-      #t15.{core::Map::[]=}(self::list.{core::List::[]}(i), 1);
+      #t15.{core::Map::[]=}{Invariant}(self::list.{core::List::[]}(i), 1);
   else
-    #t15.{core::Map::[]=}(0, 1);
+    #t15.{core::Map::[]=}{Invariant}(0, 1);
 } =>#t15;
 static field core::Map<dynamic, core::int*>* map10 = block {
   final core::Map<dynamic, core::int*>* #t16 = <dynamic, core::int*>{};
   if(self::b)
-    #t16.{core::Map::[]=}(0, 1);
+    #t16.{core::Map::[]=}{Invariant}(0, 1);
   else
     for (core::int* i = 0; i.{core::num::<}(self::list.{core::List::length}); i = i.{core::num::+}(1))
       for (final core::MapEntry<dynamic, core::int*>* #t17 in <dynamic, core::int*>{self::list.{core::List::[]}(i): 1}.{core::Map::entries})
-        #t16.{core::Map::[]=}(#t17.{core::MapEntry::key}, #t17.{core::MapEntry::value});
+        #t16.{core::Map::[]=}{Invariant}(#t17.{core::MapEntry::key}, #t17.{core::MapEntry::value});
 } =>#t16;
 static field core::Map<dynamic, core::int*>* map11 = block {
   final core::Map<dynamic, core::int*>* #t18 = <dynamic, core::int*>{};
   if(self::b)
     for (core::int* i = 0; i.{core::num::<}(self::list.{core::List::length}); i = i.{core::num::+}(1))
       for (final core::MapEntry<dynamic, core::int*>* #t19 in <dynamic, core::int*>{self::list.{core::List::[]}(i): 1}.{core::Map::entries})
-        #t18.{core::Map::[]=}(#t19.{core::MapEntry::key}, #t19.{core::MapEntry::value});
+        #t18.{core::Map::[]=}{Invariant}(#t19.{core::MapEntry::key}, #t19.{core::MapEntry::value});
   else
-    #t18.{core::Map::[]=}(0, 1);
+    #t18.{core::Map::[]=}{Invariant}(0, 1);
 } =>#t18;
 static field core::Map<core::int*, core::int*>* map12 = block {
   final core::Map<core::int*, core::int*>* #t20 = <core::int*, core::int*>{};
   if(self::b)
-    #t20.{core::Map::[]=}(0, 1);
+    #t20.{core::Map::[]=}{Invariant}(0, 1);
   else
     if(self::b)
       for (final core::MapEntry<core::int*, core::int*>* #t21 in <core::int*, core::int*>{0: 1}.{core::Map::entries})
-        #t20.{core::Map::[]=}(#t21.{core::MapEntry::key}, #t21.{core::MapEntry::value});
+        #t20.{core::Map::[]=}{Invariant}(#t21.{core::MapEntry::key}, #t21.{core::MapEntry::value});
 } =>#t20;
 static field core::Map<dynamic, Null>* error4 = <dynamic, Null>{invalid-expression "pkg/front_end/testcases/unified_collections/mixed_entries.dart:33:32: Error: Both Iterable and Map spread elements encountered in ambiguous literal.
 var error4 = {if (b) 0: 1 else for (var a in list) a};
diff --git a/pkg/front_end/testcases/unified_collections/mixed_entries.dart.strong.transformed.expect b/pkg/front_end/testcases/unified_collections/mixed_entries.dart.strong.transformed.expect
index dd3b4fe..ff07e3e 100644
--- a/pkg/front_end/testcases/unified_collections/mixed_entries.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/unified_collections/mixed_entries.dart.strong.transformed.expect
@@ -47,12 +47,12 @@
 static field core::Map<dynamic, dynamic>* map1 = block {
   final core::Map<dynamic, dynamic>* #t1 = <dynamic, dynamic>{};
   if(self::b)
-    #t1.{core::Map::[]=}(0, 1);
+    #t1.{core::Map::[]=}{Invariant}(0, 1);
   else {
     core::Iterator<core::MapEntry<dynamic, dynamic>>* :sync-for-iterator = self::map0.{core::Map::entries}.{core::Iterable::iterator};
     for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
       final core::MapEntry<dynamic, dynamic>* #t2 = :sync-for-iterator.{core::Iterator::current};
-      #t1.{core::Map::[]=}(#t2.{core::MapEntry::key}, #t2.{core::MapEntry::value});
+      #t1.{core::Map::[]=}{Invariant}(#t2.{core::MapEntry::key}, #t2.{core::MapEntry::value});
     }
   }
 } =>#t1;
@@ -62,11 +62,11 @@
     core::Iterator<core::MapEntry<dynamic, dynamic>>* :sync-for-iterator = self::map0.{core::Map::entries}.{core::Iterable::iterator};
     for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
       final core::MapEntry<dynamic, dynamic>* #t4 = :sync-for-iterator.{core::Iterator::current};
-      #t3.{core::Map::[]=}(#t4.{core::MapEntry::key}, #t4.{core::MapEntry::value});
+      #t3.{core::Map::[]=}{Invariant}(#t4.{core::MapEntry::key}, #t4.{core::MapEntry::value});
     }
   }
   else
-    #t3.{core::Map::[]=}(0, 1);
+    #t3.{core::Map::[]=}{Invariant}(0, 1);
 } =>#t3;
 static field core::Map<dynamic, dynamic>* map3 = block {
   final core::Map<dynamic, dynamic>* #t5 = <dynamic, dynamic>{};
@@ -74,26 +74,26 @@
     core::Iterator<core::MapEntry<dynamic, dynamic>>* :sync-for-iterator = self::map0.{core::Map::entries}.{core::Iterable::iterator};
     for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
       final core::MapEntry<dynamic, dynamic>* #t6 = :sync-for-iterator.{core::Iterator::current};
-      #t5.{core::Map::[]=}(#t6.{core::MapEntry::key}, #t6.{core::MapEntry::value});
+      #t5.{core::Map::[]=}{Invariant}(#t6.{core::MapEntry::key}, #t6.{core::MapEntry::value});
     }
   }
   else {
     core::Iterator<core::MapEntry<dynamic, dynamic>>* :sync-for-iterator = self::map0.{core::Map::entries}.{core::Iterable::iterator};
     for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
       final core::MapEntry<dynamic, dynamic>* #t7 = :sync-for-iterator.{core::Iterator::current};
-      #t5.{core::Map::[]=}(#t7.{core::MapEntry::key}, #t7.{core::MapEntry::value});
+      #t5.{core::Map::[]=}{Invariant}(#t7.{core::MapEntry::key}, #t7.{core::MapEntry::value});
     }
   }
 } =>#t5;
 static field core::Map<dynamic, core::int*>* map4 = block {
   final core::Map<dynamic, core::int*>* #t8 = <dynamic, core::int*>{};
   if(self::b)
-    #t8.{core::Map::[]=}(0, 1);
+    #t8.{core::Map::[]=}{Invariant}(0, 1);
   else {
     core::Iterator<dynamic>* :sync-for-iterator = self::list.{core::Iterable::iterator};
     for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
       dynamic a = :sync-for-iterator.{core::Iterator::current};
-      #t8.{core::Map::[]=}(a, 1);
+      #t8.{core::Map::[]=}{Invariant}(a, 1);
     }
   }
 } =>#t8;
@@ -103,16 +103,16 @@
     core::Iterator<dynamic>* :sync-for-iterator = self::list.{core::Iterable::iterator};
     for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
       dynamic a = :sync-for-iterator.{core::Iterator::current};
-      #t9.{core::Map::[]=}(a, 1);
+      #t9.{core::Map::[]=}{Invariant}(a, 1);
     }
   }
   else
-    #t9.{core::Map::[]=}(0, 1);
+    #t9.{core::Map::[]=}{Invariant}(0, 1);
 } =>#t9;
 static field core::Map<dynamic, core::int*>* map6 = block {
   final core::Map<dynamic, core::int*>* #t10 = <dynamic, core::int*>{};
   if(self::b)
-    #t10.{core::Map::[]=}(0, 1);
+    #t10.{core::Map::[]=}{Invariant}(0, 1);
   else {
     core::Iterator<dynamic>* :sync-for-iterator = self::list.{core::Iterable::iterator};
     for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
@@ -121,7 +121,7 @@
         core::Iterator<core::MapEntry<dynamic, core::int*>>* :sync-for-iterator = <dynamic, core::int*>{a: 1}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<dynamic, core::int*>* #t11 = :sync-for-iterator.{core::Iterator::current};
-          #t10.{core::Map::[]=}(#t11.{core::MapEntry::key}, #t11.{core::MapEntry::value});
+          #t10.{core::Map::[]=}{Invariant}(#t11.{core::MapEntry::key}, #t11.{core::MapEntry::value});
         }
       }
     }
@@ -137,40 +137,40 @@
         core::Iterator<core::MapEntry<dynamic, core::int*>>* :sync-for-iterator = <dynamic, core::int*>{a: 1}.{core::Map::entries}.{core::Iterable::iterator};
         for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
           final core::MapEntry<dynamic, core::int*>* #t13 = :sync-for-iterator.{core::Iterator::current};
-          #t12.{core::Map::[]=}(#t13.{core::MapEntry::key}, #t13.{core::MapEntry::value});
+          #t12.{core::Map::[]=}{Invariant}(#t13.{core::MapEntry::key}, #t13.{core::MapEntry::value});
         }
       }
     }
   }
   else
-    #t12.{core::Map::[]=}(0, 1);
+    #t12.{core::Map::[]=}{Invariant}(0, 1);
 } =>#t12;
 static field core::Map<dynamic, core::int*>* map8 = block {
   final core::Map<dynamic, core::int*>* #t14 = <dynamic, core::int*>{};
   if(self::b)
-    #t14.{core::Map::[]=}(0, 1);
+    #t14.{core::Map::[]=}{Invariant}(0, 1);
   else
     for (core::int* i = 0; i.{core::num::<}(self::list.{core::List::length}); i = i.{core::num::+}(1))
-      #t14.{core::Map::[]=}(self::list.{core::List::[]}(i), 1);
+      #t14.{core::Map::[]=}{Invariant}(self::list.{core::List::[]}(i), 1);
 } =>#t14;
 static field core::Map<dynamic, core::int*>* map9 = block {
   final core::Map<dynamic, core::int*>* #t15 = <dynamic, core::int*>{};
   if(self::b)
     for (core::int* i = 0; i.{core::num::<}(self::list.{core::List::length}); i = i.{core::num::+}(1))
-      #t15.{core::Map::[]=}(self::list.{core::List::[]}(i), 1);
+      #t15.{core::Map::[]=}{Invariant}(self::list.{core::List::[]}(i), 1);
   else
-    #t15.{core::Map::[]=}(0, 1);
+    #t15.{core::Map::[]=}{Invariant}(0, 1);
 } =>#t15;
 static field core::Map<dynamic, core::int*>* map10 = block {
   final core::Map<dynamic, core::int*>* #t16 = <dynamic, core::int*>{};
   if(self::b)
-    #t16.{core::Map::[]=}(0, 1);
+    #t16.{core::Map::[]=}{Invariant}(0, 1);
   else
     for (core::int* i = 0; i.{core::num::<}(self::list.{core::List::length}); i = i.{core::num::+}(1)) {
       core::Iterator<core::MapEntry<dynamic, core::int*>>* :sync-for-iterator = <dynamic, core::int*>{self::list.{core::List::[]}(i): 1}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<dynamic, core::int*>* #t17 = :sync-for-iterator.{core::Iterator::current};
-        #t16.{core::Map::[]=}(#t17.{core::MapEntry::key}, #t17.{core::MapEntry::value});
+        #t16.{core::Map::[]=}{Invariant}(#t17.{core::MapEntry::key}, #t17.{core::MapEntry::value});
       }
     }
 } =>#t16;
@@ -181,22 +181,22 @@
       core::Iterator<core::MapEntry<dynamic, core::int*>>* :sync-for-iterator = <dynamic, core::int*>{self::list.{core::List::[]}(i): 1}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<dynamic, core::int*>* #t19 = :sync-for-iterator.{core::Iterator::current};
-        #t18.{core::Map::[]=}(#t19.{core::MapEntry::key}, #t19.{core::MapEntry::value});
+        #t18.{core::Map::[]=}{Invariant}(#t19.{core::MapEntry::key}, #t19.{core::MapEntry::value});
       }
     }
   else
-    #t18.{core::Map::[]=}(0, 1);
+    #t18.{core::Map::[]=}{Invariant}(0, 1);
 } =>#t18;
 static field core::Map<core::int*, core::int*>* map12 = block {
   final core::Map<core::int*, core::int*>* #t20 = <core::int*, core::int*>{};
   if(self::b)
-    #t20.{core::Map::[]=}(0, 1);
+    #t20.{core::Map::[]=}{Invariant}(0, 1);
   else
     if(self::b) {
       core::Iterator<core::MapEntry<core::int*, core::int*>>* :sync-for-iterator = <core::int*, core::int*>{0: 1}.{core::Map::entries}.{core::Iterable::iterator};
       for (; :sync-for-iterator.{core::Iterator::moveNext}(); ) {
         final core::MapEntry<core::int*, core::int*>* #t21 = :sync-for-iterator.{core::Iterator::current};
-        #t20.{core::Map::[]=}(#t21.{core::MapEntry::key}, #t21.{core::MapEntry::value});
+        #t20.{core::Map::[]=}{Invariant}(#t21.{core::MapEntry::key}, #t21.{core::MapEntry::value});
       }
     }
 } =>#t20;
diff --git a/pkg/front_end/testcases/unified_collections/string_concatenation.dart.strong.expect b/pkg/front_end/testcases/unified_collections/string_concatenation.dart.strong.expect
index 930929b..f3953a4 100644
--- a/pkg/front_end/testcases/unified_collections/string_concatenation.dart.strong.expect
+++ b/pkg/front_end/testcases/unified_collections/string_concatenation.dart.strong.expect
@@ -6,8 +6,8 @@
   core::bool* b = false;
   block {
     final core::List<core::String*>* #t1 = <core::String*>[];
-    #t1.{core::List::add}("ab");
+    #t1.{core::List::add}{Invariant}("ab");
     if(b)
-      #t1.{core::List::add}("cd");
+      #t1.{core::List::add}{Invariant}("cd");
   } =>#t1;
 }
diff --git a/pkg/front_end/testcases/unified_collections/string_concatenation.dart.strong.transformed.expect b/pkg/front_end/testcases/unified_collections/string_concatenation.dart.strong.transformed.expect
index b5ffe41..44b114b 100644
--- a/pkg/front_end/testcases/unified_collections/string_concatenation.dart.strong.transformed.expect
+++ b/pkg/front_end/testcases/unified_collections/string_concatenation.dart.strong.transformed.expect
@@ -6,9 +6,9 @@
   core::bool* b = false;
   block {
     final core::List<core::String*>* #t1 = <core::String*>[];
-    #t1.{core::List::add}("ab");
+    #t1.{core::List::add}{Invariant}("ab");
     if(b)
-      #t1.{core::List::add}("cd");
+      #t1.{core::List::add}{Invariant}("cd");
   } =>#t1;
 }
 
diff --git a/pkg/kernel/binary.md b/pkg/kernel/binary.md
index 6a26a6d..cafad21 100644
--- a/pkg/kernel/binary.md
+++ b/pkg/kernel/binary.md
@@ -631,6 +631,7 @@
 
 type MethodInvocation extends Expression {
   Byte tag = 28;
+  Byte flags;
   FileOffset fileOffset;
   Expression receiver;
   Name name;
@@ -1024,6 +1025,7 @@
 type Block extends Statement {
   Byte tag = 62;
   FileOffset fileOffset;
+  FileOffset fileEndOffset;
   List<Statement> statements;
 }
 
diff --git a/pkg/kernel/lib/ast.dart b/pkg/kernel/lib/ast.dart
index 7df2713..ce1824e 100644
--- a/pkg/kernel/lib/ast.dart
+++ b/pkg/kernel/lib/ast.dart
@@ -3778,9 +3778,14 @@
 
 /// Expression of form `x.foo(y)`.
 class MethodInvocation extends InvocationExpression {
+  // Must match serialized bit positions.
+  static const int FlagInvariant = 1 << 0;
+  static const int FlagBoundsSafe = 1 << 1;
+
   Expression receiver;
   Name name;
   Arguments arguments;
+  int flags = 0;
 
   Reference interfaceTargetReference;
 
@@ -3806,6 +3811,41 @@
     interfaceTargetReference = getMemberReferenceGetter(target);
   }
 
+  /// If `true`, this call is known to be safe wrt. parameter covariance checks.
+  ///
+  /// This is for instance the case in code patterns like this
+  ///
+  ///     List<int> list = <int>[];
+  ///     list.add(0);
+  ///
+  /// where the `list` variable is known to hold a value of the same type as
+  /// the static type. In contrast the would not be the case in code patterns
+  /// like this
+  ///
+  ///     List<num> list = <double>[];
+  ///     list.add(0); // Runtime error `int` is not a subtype of `double`.
+  ///
+  bool get isInvariant => flags & FlagInvariant != 0;
+
+  void set isInvariant(bool value) {
+    flags = value ? (flags | FlagInvariant) : (flags & ~FlagInvariant);
+  }
+
+  /// If `true`, this call is known to be safe wrt. parameter covariance checks.
+  ///
+  /// This is for instance the case in code patterns like this
+  ///
+  ///     List list = new List.filled(2, 0);
+  ///     list[1] = 42;
+  ///
+  /// where the `list` is known to have a sufficient length for the update
+  /// in `list[1] = 42`.
+  bool get isBoundsSafe => flags & FlagBoundsSafe != 0;
+
+  void set isBoundsSafe(bool value) {
+    flags = value ? (flags | FlagBoundsSafe) : (flags & ~FlagBoundsSafe);
+  }
+
   DartType getStaticTypeInternal(StaticTypeContext context) {
     var interfaceTarget = this.interfaceTarget;
     if (interfaceTarget != null) {
@@ -5879,6 +5919,11 @@
 class Block extends Statement {
   final List<Statement> statements;
 
+  /// End offset in the source file it comes from. Valid values are from 0 and
+  /// up, or -1 ([TreeNode.noOffset]) if the file end offset is not available
+  /// (this is the default if none is specifically set).
+  int fileEndOffset = TreeNode.noOffset;
+
   Block(this.statements) {
     // Ensure statements is mutable.
     assert((statements
diff --git a/pkg/kernel/lib/binary/ast_from_binary.dart b/pkg/kernel/lib/binary/ast_from_binary.dart
index 97bda78..c0af19e 100644
--- a/pkg/kernel/lib/binary/ast_from_binary.dart
+++ b/pkg/kernel/lib/binary/ast_from_binary.dart
@@ -1711,10 +1711,12 @@
             readMemberReference(), readExpression())
           ..fileOffset = offset;
       case Tag.MethodInvocation:
+        int flags = readByte();
         int offset = readOffset();
         return new MethodInvocation.byReference(readExpression(), readName(),
             readArguments(), readInstanceMemberReference(allowNull: true))
-          ..fileOffset = offset;
+          ..fileOffset = offset
+          ..flags = flags;
       case Tag.SuperMethodInvocation:
         int offset = readOffset();
         addTransformerFlag(TransformerFlag.superCalls);
@@ -2106,9 +2108,12 @@
   Block readBlock() {
     int stackHeight = variableStack.length;
     var offset = readOffset();
+    var endOffset = readOffset();
     var body = readStatementList();
     variableStack.length = stackHeight;
-    return new Block(body)..fileOffset = offset;
+    return new Block(body)
+      ..fileOffset = offset
+      ..fileEndOffset = endOffset;
   }
 
   AssertBlock readAssertBlock() {
diff --git a/pkg/kernel/lib/binary/ast_to_binary.dart b/pkg/kernel/lib/binary/ast_to_binary.dart
index a0940ff..e7bd343 100644
--- a/pkg/kernel/lib/binary/ast_to_binary.dart
+++ b/pkg/kernel/lib/binary/ast_to_binary.dart
@@ -1466,6 +1466,7 @@
   @override
   void visitMethodInvocation(MethodInvocation node) {
     writeByte(Tag.MethodInvocation);
+    writeByte(node.flags);
     writeOffset(node.fileOffset);
     writeNode(node.receiver);
     writeName(node.name);
@@ -1812,6 +1813,7 @@
     _variableIndexer.pushScope();
     writeByte(Tag.Block);
     writeOffset(node.fileOffset);
+    writeOffset(node.fileEndOffset);
     writeNodeList(node.statements);
     _variableIndexer.popScope();
   }
diff --git a/pkg/kernel/lib/clone.dart b/pkg/kernel/lib/clone.dart
index d70b550..c14b8d16 100644
--- a/pkg/kernel/lib/clone.dart
+++ b/pkg/kernel/lib/clone.dart
@@ -158,7 +158,8 @@
 
   visitMethodInvocation(MethodInvocation node) {
     return new MethodInvocation.byReference(clone(node.receiver), node.name,
-        clone(node.arguments), node.interfaceTargetReference);
+        clone(node.arguments), node.interfaceTargetReference)
+      ..flags = node.flags;
   }
 
   visitSuperMethodInvocation(SuperMethodInvocation node) {
diff --git a/pkg/kernel/lib/text/ast_to_text.dart b/pkg/kernel/lib/text/ast_to_text.dart
index 1e05d07..e05a4b6 100644
--- a/pkg/kernel/lib/text/ast_to_text.dart
+++ b/pkg/kernel/lib/text/ast_to_text.dart
@@ -1349,6 +1349,16 @@
     writeExpression(node.receiver, Precedence.PRIMARY);
     writeSymbol('.');
     writeInterfaceTarget(node.name, node.interfaceTargetReference);
+    List<String> flags = <String>[];
+    if (node.isInvariant) {
+      flags.add('Invariant');
+    }
+    if (node.isBoundsSafe) {
+      flags.add('BoundsSafe');
+    }
+    if (flags.isNotEmpty) {
+      write('{${flags.join(',')}}');
+    }
     writeNode(node.arguments);
   }
 
diff --git a/pkg/nnbd_migration/lib/src/messages.dart b/pkg/nnbd_migration/lib/src/messages.dart
index 1305da4..f4796c1 100644
--- a/pkg/nnbd_migration/lib/src/messages.dart
+++ b/pkg/nnbd_migration/lib/src/messages.dart
@@ -18,7 +18,8 @@
 Warning: package has unmigrated dependencies.
 
 Continuing due to the presence of `$_skipImportCheckFlag`.  To see a complete
- list of these libraries, re-run without the `$_skipImportCheckFlag` flag.
+list of the unmigrated dependencies, re-run without the `$_skipImportCheckFlag`
+flag.
 ''';
 
 String unmigratedDependenciesError(List<String> uris) => '''
diff --git a/pkg/nnbd_migration/lib/src/nullability_migration_impl.dart b/pkg/nnbd_migration/lib/src/nullability_migration_impl.dart
index f80f4c4..81a3079 100644
--- a/pkg/nnbd_migration/lib/src/nullability_migration_impl.dart
+++ b/pkg/nnbd_migration/lib/src/nullability_migration_impl.dart
@@ -217,7 +217,10 @@
       return;
     }
     ExperimentStatusException.sanityCheck(result);
-    _recordTransitiveImportOptInStatus(result.libraryElement.importedLibraries);
+    _recordTransitiveImportExportOptInStatus(
+        result.libraryElement.importedLibraries);
+    _recordTransitiveImportExportOptInStatus(
+        result.libraryElement.exportedLibraries);
     if (_variables == null) {
       _variables = Variables(_graph, result.typeProvider, _getLineInfo,
           instrumentation: _instrumentation,
@@ -270,14 +273,16 @@
   }
 
   /// Records the opt in/out status of all libraries in [libraries], and any
-  /// libraries they transitively import, in [_libraryOptInStatus].
-  void _recordTransitiveImportOptInStatus(Iterable<LibraryElement> libraries) {
+  /// libraries they transitively import or export, in [_libraryOptInStatus].
+  void _recordTransitiveImportExportOptInStatus(
+      Iterable<LibraryElement> libraries) {
     var librariesToCheck = libraries.toList();
     while (librariesToCheck.isNotEmpty) {
       var library = librariesToCheck.removeLast();
       if (_libraryOptInStatus.containsKey(library.source)) continue;
       _libraryOptInStatus[library.source] = library.isNonNullableByDefault;
       librariesToCheck.addAll(library.importedLibraries);
+      librariesToCheck.addAll(library.exportedLibraries);
     }
   }
 
diff --git a/pkg/nnbd_migration/test/migration_cli_test.dart b/pkg/nnbd_migration/test/migration_cli_test.dart
index c581b6b..ce0ec97 100644
--- a/pkg/nnbd_migration/test/migration_cli_test.dart
+++ b/pkg/nnbd_migration/test/migration_cli_test.dart
@@ -762,6 +762,50 @@
     });
   }
 
+  test_lifecycle_import_check_via_export() async {
+    // If the user's code exports a library that imports a non-migrated library,
+    // that's a problem too.
+    var projectContents = simpleProject(
+        sourceText: "export 'package:foo/foo.dart';",
+        packageConfigText: _getPackageConfigText(
+            migrated: false, packagesMigrated: {'foo': true, 'bar': false}));
+    var projectDir = createProjectDir(projectContents);
+    resourceProvider.newFile(
+        packagePath('foo/lib/foo.dart'), "import 'package:bar/bar.dart';");
+    resourceProvider.newFile(packagePath('bar/lib/bar.dart'), '');
+    await assertRunFailure([projectDir], expectedExitCode: 1);
+    var output = logger.stdoutBuffer.toString();
+    expect(output, contains('Error: package has unmigrated dependencies'));
+    // Output should mention bar.dart, since it's unmigrated
+    expect(output, contains('package:bar/bar.dart'));
+    // But it should not mention foo.dart, which is migrated
+    expect(output, isNot(contains('package:foo/foo.dart')));
+  }
+
+  test_lifecycle_import_check_via_indirect_export() async {
+    // If the user's code imports a library that exports a library that imports
+    // a non-migrated library, that's a problem too.
+    var projectContents = simpleProject(
+        sourceText: "import 'package:foo/foo.dart';",
+        packageConfigText: _getPackageConfigText(
+            migrated: false,
+            packagesMigrated: {'foo': true, 'bar': true, 'baz': false}));
+    var projectDir = createProjectDir(projectContents);
+    resourceProvider.newFile(
+        packagePath('foo/lib/foo.dart'), "export 'package:bar/bar.dart';");
+    resourceProvider.newFile(
+        packagePath('bar/lib/bar.dart'), "import 'package:baz/baz.dart';");
+    resourceProvider.newFile(packagePath('baz/lib/baz.dart'), '');
+    await assertRunFailure([projectDir], expectedExitCode: 1);
+    var output = logger.stdoutBuffer.toString();
+    expect(output, contains('Error: package has unmigrated dependencies'));
+    // Output should mention baz.dart, since it's unmigrated
+    expect(output, contains('package:baz/baz.dart'));
+    // But it should not mention foo.dart or bar.dart, which are migrated
+    expect(output, isNot(contains('package:foo/foo.dart')));
+    expect(output, isNot(contains('package:bar/bar.dart')));
+  }
+
   test_lifecycle_no_preview() async {
     var projectContents = simpleProject();
     var projectDir = createProjectDir(projectContents);
diff --git a/runtime/observatory/tests/service/dds_extension_event_history_test.dart b/runtime/observatory/tests/service/dds_extension_event_history_test.dart
new file mode 100644
index 0000000..0c3d165
--- /dev/null
+++ b/runtime/observatory/tests/service/dds_extension_event_history_test.dart
@@ -0,0 +1,52 @@
+// Copyright (c) 2020, the Dart project authors.  Please see the AUTHORS file
+// for details. All rights reserved. Use of this source code is governed by a
+// BSD-style license that can be found in the LICENSE file.
+
+import 'dart:async';
+import 'dart:developer';
+
+import 'package:observatory/service_io.dart';
+import 'package:test/test.dart';
+import 'client_resume_approvals_common.dart';
+import 'service_test_common.dart';
+import 'test_helper.dart';
+
+Future testMain() async {
+  // Post a total of 9 events
+  for (int i = 1; i <= 9; ++i) {
+    postEvent('Test', {
+      'id': i,
+    });
+  }
+}
+
+var tests = <IsolateTest>[
+  isPausedAtStart,
+  resumeIsolate,
+  (Isolate isolate) async {
+    final completer = Completer<void>();
+    int i = 1;
+    await subscribeToStream(isolate.vm, 'Extension', (event) async {
+      expect(event.extensionKind, 'Test');
+      expect(event.extensionData!['id'], i);
+      i++;
+
+      if (i == 10) {
+        await cancelStreamSubscription('Extension');
+        completer.complete();
+      } else if (i > 10) {
+        fail('Too many log messages');
+      }
+    });
+    await completer.future;
+  },
+];
+
+main(args) => runIsolateTests(
+      args,
+      tests,
+      enableService: false, // DDS specific feature
+      testeeConcurrent: testMain,
+      pause_on_start: true,
+      pause_on_exit: true,
+    );
diff --git a/runtime/observatory/tests/service/dds_stdout_stderr_history_test.dart b/runtime/observatory/tests/service/dds_stdout_stderr_history_test.dart
new file mode 100644
index 0000000..c0d6ba5
--- /dev/null
+++ b/runtime/observatory/tests/service/dds_stdout_stderr_history_test.dart
@@ -0,0 +1,61 @@
+// Copyright (c) 2020, the Dart project authors.  Please see the AUTHORS file
+// for details. All rights reserved. Use of this source code is governed by a
+// BSD-style license that can be found in the LICENSE file.
+
+import 'dart:async';
+import 'dart:io';
+
+import 'package:observatory/service_io.dart';
+import 'package:test/test.dart';
+import 'client_resume_approvals_common.dart';
+import 'service_test_common.dart';
+import 'test_helper.dart';
+
+Future testMain() async {
+  // Log a total of 9 messages
+  for (int i = 1; i <= 9; ++i) {
+    print('Stdout log$i');
+    stderr.writeln('Stderr log$i');
+  }
+}
+
+Future streamHistoryTest(Isolate isolate, String stream) async {
+  final completer = Completer<void>();
+  int i = 1;
+  await subscribeToStream(isolate.vm, stream, (event) async {
+    // Newlines are sent as separate events for some reason. Ignore them.
+    if (!event.bytesAsString!.startsWith(stream)) {
+      return;
+    }
+    expect(event.bytesAsString, '$stream log$i');
+    i++;
+
+    if (i == 10) {
+      await cancelStreamSubscription(stream);
+      completer.complete();
+    } else if (i > 10) {
+      fail('Too many log messages');
+    }
+  });
+  await completer.future;
+}
+
+var tests = <IsolateTest>[
+  isPausedAtStart,
+  resumeIsolate,
+  (Isolate isolate) async {
+    await streamHistoryTest(isolate, 'Stdout');
+  },
+  (Isolate isolate) async {
+    await streamHistoryTest(isolate, 'Stderr');
+  },
+];
+
+main(args) => runIsolateTests(
+      args,
+      tests,
+      enableService: false, // DDS specific feature
+      testeeConcurrent: testMain,
+      pause_on_start: true,
+      pause_on_exit: true,
+    );
diff --git a/runtime/observatory/tests/service/network_profiling_test.dart b/runtime/observatory/tests/service/network_profiling_test.dart
index d68fbeb..3a318ca 100644
--- a/runtime/observatory/tests/service/network_profiling_test.dart
+++ b/runtime/observatory/tests/service/network_profiling_test.dart
@@ -56,11 +56,14 @@
   postEvent('socketTest', {'socket': 'test'});
 }
 
-void checkFinishEvent(ServiceEvent event) {
+bool checkFinishEvent(ServiceEvent event) {
   expect(event.kind, equals(ServiceEvent.kExtension));
-  expect(event.extensionKind, equals('socketTest'));
+  if (event.extensionKind != 'socketTest') {
+    return false;
+  }
   expect(event.extensionData, isA<Map>());
   expect(event.extensionData!['socket'], equals('test'));
+  return true;
 }
 
 var tests = <IsolateTest>[
@@ -102,9 +105,10 @@
     var sub;
     sub = await isolate.vm.listenEventStream(Isolate.kExtensionStream,
         (ServiceEvent event) {
-      checkFinishEvent(event);
-      sub.cancel();
-      completer.complete();
+      if (checkFinishEvent(event)) {
+        sub.cancel();
+        completer.complete();
+      }
     });
 
     dynamic result = await isolate.invokeRpc("invoke",
@@ -150,9 +154,10 @@
       completer = Completer();
       sub = await isolate.vm.listenEventStream(Isolate.kExtensionStream,
           (ServiceEvent event) {
-        checkFinishEvent(event);
-        sub.cancel();
-        completer.complete();
+        if (checkFinishEvent(event)) {
+          sub.cancel();
+          completer.complete();
+        }
       });
       dynamic result = await isolate.invokeRpc("invoke",
           {"targetId": lib.id, "selector": "socketTest", "argumentIds": []});
@@ -197,9 +202,10 @@
     var sub;
     sub = await isolate.vm.listenEventStream(Isolate.kExtensionStream,
         (ServiceEvent event) {
-      checkFinishEvent(event);
-      sub.cancel();
-      completer.complete();
+      if (checkFinishEvent(event)) {
+        sub.cancel();
+        completer.complete();
+      }
     });
 
     dynamic result = await isolate.invokeRpc("invoke",
diff --git a/runtime/observatory_2/tests/service_2/dds_extension_event_history_test.dart b/runtime/observatory_2/tests/service_2/dds_extension_event_history_test.dart
new file mode 100644
index 0000000..ea8ab07
--- /dev/null
+++ b/runtime/observatory_2/tests/service_2/dds_extension_event_history_test.dart
@@ -0,0 +1,52 @@
+// Copyright (c) 2020, the Dart project authors.  Please see the AUTHORS file
+// for details. All rights reserved. Use of this source code is governed by a
+// BSD-style license that can be found in the LICENSE file.
+
+import 'dart:async';
+import 'dart:developer';
+
+import 'package:observatory_2/service_io.dart';
+import 'package:test/test.dart';
+import 'client_resume_approvals_common.dart';
+import 'service_test_common.dart';
+import 'test_helper.dart';
+
+Future testMain() async {
+  // Post a total of 9 events
+  for (int i = 1; i <= 9; ++i) {
+    postEvent('Test', {
+      'id': i,
+    });
+  }
+}
+
+var tests = <IsolateTest>[
+  isPausedAtStart,
+  resumeIsolate,
+  (Isolate isolate) async {
+    final completer = Completer<void>();
+    int i = 1;
+    await subscribeToStream(isolate.vm, 'Extension', (event) async {
+      expect(event.extensionKind, 'Test');
+      expect(event.extensionData['id'], i);
+      i++;
+
+      if (i == 10) {
+        await cancelStreamSubscription('Extension');
+        completer.complete();
+      } else if (i > 10) {
+        fail('Too many log messages');
+      }
+    });
+    await completer.future;
+  },
+];
+
+main(args) => runIsolateTests(
+      args,
+      tests,
+      enableService: false, // DDS specific feature
+      testeeConcurrent: testMain,
+      pause_on_start: true,
+      pause_on_exit: true,
+    );
diff --git a/runtime/observatory_2/tests/service_2/dds_stdout_stderr_history_test.dart b/runtime/observatory_2/tests/service_2/dds_stdout_stderr_history_test.dart
new file mode 100644
index 0000000..9fc0b7a
--- /dev/null
+++ b/runtime/observatory_2/tests/service_2/dds_stdout_stderr_history_test.dart
@@ -0,0 +1,61 @@
+// Copyright (c) 2020, the Dart project authors.  Please see the AUTHORS file
+// for details. All rights reserved. Use of this source code is governed by a
+// BSD-style license that can be found in the LICENSE file.
+
+import 'dart:async';
+import 'dart:io';
+
+import 'package:observatory_2/service_io.dart';
+import 'package:test/test.dart';
+import 'client_resume_approvals_common.dart';
+import 'service_test_common.dart';
+import 'test_helper.dart';
+
+Future testMain() async {
+  // Log a total of 9 messages
+  for (int i = 1; i <= 9; ++i) {
+    print('Stdout log$i');
+    stderr.writeln('Stderr log$i');
+  }
+}
+
+Future streamHistoryTest(Isolate isolate, String stream) async {
+  final completer = Completer<void>();
+  int i = 1;
+  await subscribeToStream(isolate.vm, stream, (event) async {
+    // Newlines are sent as separate events for some reason. Ignore them.
+    if (!event.bytesAsString.startsWith(stream)) {
+      return;
+    }
+    expect(event.bytesAsString, '$stream log$i');
+    i++;
+
+    if (i == 10) {
+      await cancelStreamSubscription(stream);
+      completer.complete();
+    } else if (i > 10) {
+      fail('Too many log messages');
+    }
+  });
+  await completer.future;
+}
+
+var tests = <IsolateTest>[
+  isPausedAtStart,
+  resumeIsolate,
+  (Isolate isolate) async {
+    await streamHistoryTest(isolate, 'Stdout');
+  },
+  (Isolate isolate) async {
+    await streamHistoryTest(isolate, 'Stderr');
+  },
+];
+
+main(args) => runIsolateTests(
+      args,
+      tests,
+      enableService: false, // DDS specific feature
+      testeeConcurrent: testMain,
+      pause_on_start: true,
+      pause_on_exit: true,
+    );
diff --git a/runtime/observatory_2/tests/service_2/network_profiling_test.dart b/runtime/observatory_2/tests/service_2/network_profiling_test.dart
index 5c27795..8ba995f 100644
--- a/runtime/observatory_2/tests/service_2/network_profiling_test.dart
+++ b/runtime/observatory_2/tests/service_2/network_profiling_test.dart
@@ -56,11 +56,14 @@
   postEvent('socketTest', {'socket': 'test'});
 }
 
-Future<void> checkFinishEvent(ServiceEvent event) {
+bool checkFinishEvent(ServiceEvent event) {
   expect(event.kind, equals(ServiceEvent.kExtension));
-  expect(event.extensionKind, equals('socketTest'));
+  if (event.extensionKind != 'socketTest') {
+    return false;
+  }
   expect(event.extensionData, isA<Map>());
   expect(event.extensionData['socket'], equals('test'));
+  return true;
 }
 
 var tests = <IsolateTest>[
@@ -102,9 +105,10 @@
     var sub;
     sub = await isolate.vm.listenEventStream(Isolate.kExtensionStream,
         (ServiceEvent event) {
-      checkFinishEvent(event);
-      sub.cancel();
-      completer.complete();
+      if (checkFinishEvent(event)) {
+        sub.cancel();
+        completer.complete();
+      }
     });
 
     dynamic result = await isolate.invokeRpc("invoke",
@@ -150,9 +154,10 @@
       completer = Completer();
       sub = await isolate.vm.listenEventStream(Isolate.kExtensionStream,
           (ServiceEvent event) {
-        checkFinishEvent(event);
-        sub.cancel();
-        completer.complete();
+        if (checkFinishEvent(event)) {
+          sub.cancel();
+          completer.complete();
+        }
       });
       dynamic result = await isolate.invokeRpc("invoke",
           {"targetId": lib.id, "selector": "socketTest", "argumentIds": []});
@@ -197,9 +202,10 @@
     var sub;
     sub = await isolate.vm.listenEventStream(Isolate.kExtensionStream,
         (ServiceEvent event) {
-      checkFinishEvent(event);
-      sub.cancel();
-      completer.complete();
+      if (checkFinishEvent(event)) {
+        sub.cancel();
+        completer.complete();
+      }
     });
 
     dynamic result = await isolate.invokeRpc("invoke",
diff --git a/runtime/vm/class_finalizer.cc b/runtime/vm/class_finalizer.cc
index bd07103..556b548 100644
--- a/runtime/vm/class_finalizer.cc
+++ b/runtime/vm/class_finalizer.cc
@@ -1386,6 +1386,7 @@
   // Prevent background compiler from adding deferred classes or canonicalizing
   // new types while classes are being sorted and type hashes are modified.
   BackgroundCompiler::Stop(I);
+  SafepointWriteRwLocker ml(T, T->isolate_group()->program_lock());
 
   ClassTable* table = I->class_table();
   intptr_t num_cids = table->NumCids();
diff --git a/runtime/vm/compiler/backend/il.cc b/runtime/vm/compiler/backend/il.cc
index fa55d52..8d8abf9 100644
--- a/runtime/vm/compiler/backend/il.cc
+++ b/runtime/vm/compiler/backend/il.cc
@@ -269,10 +269,14 @@
   Zone* zone = thread()->zone();
   GrowableArray<intptr_t> cids;
   SubclassFinder finder(zone, &cids, include_abstract);
-  if (use_subtype_test) {
-    finder.ScanImplementorClasses(dst_klass);
-  } else {
-    finder.ScanSubClasses(dst_klass);
+  {
+    SafepointReadRwLocker ml(thread(),
+                             thread()->isolate_group()->program_lock());
+    if (use_subtype_test) {
+      finder.ScanImplementorClasses(dst_klass);
+    } else {
+      finder.ScanSubClasses(dst_klass);
+    }
   }
 
   // Sort all collected cids.
diff --git a/runtime/vm/compiler/call_specializer.cc b/runtime/vm/compiler/call_specializer.cc
index d1ad68b..c096c35 100644
--- a/runtime/vm/compiler/call_specializer.cc
+++ b/runtime/vm/compiler/call_specializer.cc
@@ -1515,6 +1515,7 @@
 
   auto& td_class = Class::Handle(Z);
   auto& direct_implementors = GrowableObjectArray::Handle(Z);
+  SafepointReadRwLocker ml(thread_, thread_->isolate_group()->program_lock());
 
 #define INIT_HANDLE(iface, member_name, type, cid)                             \
   td_class = typed_data.LookupClass(Symbols::iface());                         \
diff --git a/runtime/vm/compiler/cha.cc b/runtime/vm/compiler/cha.cc
index b7160d3..eed831e 100644
--- a/runtime/vm/compiler/cha.cc
+++ b/runtime/vm/compiler/cha.cc
@@ -43,6 +43,8 @@
     // Class Object has subclasses, although we do not keep track of them.
     return true;
   }
+  Thread* thread = Thread::Current();
+  SafepointReadRwLocker ml(thread, thread->isolate_group()->program_lock());
   const GrowableObjectArray& direct_subclasses =
       GrowableObjectArray::Handle(cls.direct_subclasses());
   return !direct_subclasses.IsNull() && (direct_subclasses.Length() > 0);
@@ -63,8 +65,11 @@
     class_ids->Add(cls.id());
   }
 
+  // This is invoked from precompiler only, we can use unsafe version of
+  // Class::direct_subclasses getter.
+  ASSERT(FLAG_precompiled_mode);
   const GrowableObjectArray& direct_subclasses =
-      GrowableObjectArray::Handle(cls.direct_subclasses());
+      GrowableObjectArray::Handle(cls.direct_subclasses_unsafe());
   if (direct_subclasses.IsNull()) {
     return true;
   }
diff --git a/runtime/vm/compiler/frontend/kernel_binary_flowgraph.cc b/runtime/vm/compiler/frontend/kernel_binary_flowgraph.cc
index 75cb4a5..c5a05cd 100644
--- a/runtime/vm/compiler/frontend/kernel_binary_flowgraph.cc
+++ b/runtime/vm/compiler/frontend/kernel_binary_flowgraph.cc
@@ -2687,6 +2687,7 @@
 
 Fragment StreamingFlowGraphBuilder::BuildMethodInvocation(TokenPosition* p) {
   const intptr_t offset = ReaderOffset() - 1;     // Include the tag.
+  ReadFlags();                                    // read flags.
   const TokenPosition position = ReadPosition();  // read position.
   if (p != NULL) *p = position;
 
@@ -3927,7 +3928,8 @@
   Fragment instructions;
 
   instructions += EnterScope(offset);
-  ReadPosition();
+  ReadPosition();                           // read file offset.
+  ReadPosition();                           // read file end offset.
   intptr_t list_length = ReadListLength();  // read number of statements.
   for (intptr_t i = 0; i < list_length; ++i) {
     if (instructions.is_open()) {
diff --git a/runtime/vm/compiler/frontend/kernel_fingerprints.cc b/runtime/vm/compiler/frontend/kernel_fingerprints.cc
index f42a953..0a40040 100644
--- a/runtime/vm/compiler/frontend/kernel_fingerprints.cc
+++ b/runtime/vm/compiler/frontend/kernel_fingerprints.cc
@@ -410,6 +410,7 @@
       CalculateExpressionFingerprint();     // read expression.
       return;
     case kMethodInvocation:
+      ReadFlags();                               // read flags.
       ReadPosition();                            // read position.
       CalculateExpressionFingerprint();          // read receiver.
       BuildHash(ReadNameAsMethodName().Hash());  // read name.
@@ -583,7 +584,8 @@
       CalculateExpressionFingerprint();  // read expression.
       return;
     case kBlock:
-      ReadPosition();
+      ReadPosition();  // read file offset.
+      ReadPosition();  // read file end offset.
       CalculateStatementListFingerprint();
       return;
     case kEmptyStatement:
diff --git a/runtime/vm/compiler/frontend/kernel_translation_helper.cc b/runtime/vm/compiler/frontend/kernel_translation_helper.cc
index 3a626ba..5c28b56 100644
--- a/runtime/vm/compiler/frontend/kernel_translation_helper.cc
+++ b/runtime/vm/compiler/frontend/kernel_translation_helper.cc
@@ -2345,6 +2345,7 @@
       SkipExpression();              // read expression.
       return;
     case kMethodInvocation:
+      ReadFlags();                   // read flags.
       ReadPosition();                // read position.
       SkipExpression();              // read receiver.
       SkipName();                    // read name.
@@ -2513,7 +2514,8 @@
       SkipExpression();  // read expression.
       return;
     case kBlock:
-      ReadPosition();
+      ReadPosition();  // read file offset.
+      ReadPosition();  // read file end offset.
       SkipStatementList();
       return;
     case kEmptyStatement:
diff --git a/runtime/vm/compiler/frontend/scope_builder.cc b/runtime/vm/compiler/frontend/scope_builder.cc
index aeed3f4..4470cee 100644
--- a/runtime/vm/compiler/frontend/scope_builder.cc
+++ b/runtime/vm/compiler/frontend/scope_builder.cc
@@ -805,6 +805,7 @@
       VisitExpression();                     // read expression.
       return;
     case kMethodInvocation:
+      helper_.ReadFlags();     // read flags.
       helper_.ReadPosition();  // read position.
       VisitExpression();       // read receiver.
       helper_.SkipName();      // read name.
@@ -1021,6 +1022,7 @@
 
       EnterScope(offset);
       helper_.ReadPosition();  // read block start offset.
+      helper_.ReadPosition();  // read block end offset.
       intptr_t list_length =
           helper_.ReadListLength();  // read number of statements.
       for (intptr_t i = 0; i < list_length; ++i) {
diff --git a/runtime/vm/compiler/jit/compiler.cc b/runtime/vm/compiler/jit/compiler.cc
index e122c5f..cd282c3 100644
--- a/runtime/vm/compiler/jit/compiler.cc
+++ b/runtime/vm/compiler/jit/compiler.cc
@@ -620,6 +620,10 @@
           CheckIfBackgroundCompilerIsBeingStopped(optimized());
         }
 
+        // Grab read program_lock outside of potential safepoint, that lock
+        // can't be waited for inside the safepoint.
+        SafepointReadRwLocker ml(thread(),
+                                 thread()->isolate_group()->program_lock());
         // We have to ensure no mutators are running, because:
         //
         //   a) We allocate an instructions object, which might cause us to
diff --git a/runtime/vm/compiler/runtime_offsets_extracted.h b/runtime/vm/compiler/runtime_offsets_extracted.h
index 52fcd87..7263afe 100644
--- a/runtime/vm/compiler/runtime_offsets_extracted.h
+++ b/runtime/vm/compiler/runtime_offsets_extracted.h
@@ -2559,7 +2559,7 @@
 static constexpr dart::compiler::target::word PatchClass_InstanceSize = 24;
 static constexpr dart::compiler::target::word PcDescriptors_HeaderSize = 8;
 static constexpr dart::compiler::target::word Pointer_InstanceSize = 12;
-static constexpr dart::compiler::target::word ReceivePort_InstanceSize = 20;
+static constexpr dart::compiler::target::word ReceivePort_InstanceSize = 12;
 static constexpr dart::compiler::target::word RedirectionData_InstanceSize = 16;
 static constexpr dart::compiler::target::word RegExp_InstanceSize = 60;
 static constexpr dart::compiler::target::word Script_InstanceSize = 56;
@@ -3073,7 +3073,7 @@
 static constexpr dart::compiler::target::word PatchClass_InstanceSize = 48;
 static constexpr dart::compiler::target::word PcDescriptors_HeaderSize = 16;
 static constexpr dart::compiler::target::word Pointer_InstanceSize = 24;
-static constexpr dart::compiler::target::word ReceivePort_InstanceSize = 40;
+static constexpr dart::compiler::target::word ReceivePort_InstanceSize = 24;
 static constexpr dart::compiler::target::word RedirectionData_InstanceSize = 32;
 static constexpr dart::compiler::target::word RegExp_InstanceSize = 120;
 static constexpr dart::compiler::target::word Script_InstanceSize = 96;
@@ -3578,7 +3578,7 @@
 static constexpr dart::compiler::target::word PatchClass_InstanceSize = 24;
 static constexpr dart::compiler::target::word PcDescriptors_HeaderSize = 8;
 static constexpr dart::compiler::target::word Pointer_InstanceSize = 12;
-static constexpr dart::compiler::target::word ReceivePort_InstanceSize = 20;
+static constexpr dart::compiler::target::word ReceivePort_InstanceSize = 12;
 static constexpr dart::compiler::target::word RedirectionData_InstanceSize = 16;
 static constexpr dart::compiler::target::word RegExp_InstanceSize = 60;
 static constexpr dart::compiler::target::word Script_InstanceSize = 56;
@@ -4093,7 +4093,7 @@
 static constexpr dart::compiler::target::word PatchClass_InstanceSize = 48;
 static constexpr dart::compiler::target::word PcDescriptors_HeaderSize = 16;
 static constexpr dart::compiler::target::word Pointer_InstanceSize = 24;
-static constexpr dart::compiler::target::word ReceivePort_InstanceSize = 40;
+static constexpr dart::compiler::target::word ReceivePort_InstanceSize = 24;
 static constexpr dart::compiler::target::word RedirectionData_InstanceSize = 32;
 static constexpr dart::compiler::target::word RegExp_InstanceSize = 120;
 static constexpr dart::compiler::target::word Script_InstanceSize = 96;
@@ -6377,7 +6377,7 @@
 static constexpr dart::compiler::target::word AOT_PatchClass_InstanceSize = 20;
 static constexpr dart::compiler::target::word AOT_PcDescriptors_HeaderSize = 8;
 static constexpr dart::compiler::target::word AOT_Pointer_InstanceSize = 12;
-static constexpr dart::compiler::target::word AOT_ReceivePort_InstanceSize = 20;
+static constexpr dart::compiler::target::word AOT_ReceivePort_InstanceSize = 12;
 static constexpr dart::compiler::target::word AOT_RedirectionData_InstanceSize =
     16;
 static constexpr dart::compiler::target::word AOT_RegExp_InstanceSize = 60;
@@ -6944,7 +6944,7 @@
 static constexpr dart::compiler::target::word AOT_PatchClass_InstanceSize = 40;
 static constexpr dart::compiler::target::word AOT_PcDescriptors_HeaderSize = 16;
 static constexpr dart::compiler::target::word AOT_Pointer_InstanceSize = 24;
-static constexpr dart::compiler::target::word AOT_ReceivePort_InstanceSize = 40;
+static constexpr dart::compiler::target::word AOT_ReceivePort_InstanceSize = 24;
 static constexpr dart::compiler::target::word AOT_RedirectionData_InstanceSize =
     32;
 static constexpr dart::compiler::target::word AOT_RegExp_InstanceSize = 120;
@@ -7515,7 +7515,7 @@
 static constexpr dart::compiler::target::word AOT_PatchClass_InstanceSize = 40;
 static constexpr dart::compiler::target::word AOT_PcDescriptors_HeaderSize = 16;
 static constexpr dart::compiler::target::word AOT_Pointer_InstanceSize = 24;
-static constexpr dart::compiler::target::word AOT_ReceivePort_InstanceSize = 40;
+static constexpr dart::compiler::target::word AOT_ReceivePort_InstanceSize = 24;
 static constexpr dart::compiler::target::word AOT_RedirectionData_InstanceSize =
     32;
 static constexpr dart::compiler::target::word AOT_RegExp_InstanceSize = 120;
diff --git a/runtime/vm/heap/safepoint.h b/runtime/vm/heap/safepoint.h
index 7c3dde1..faf9c46 100644
--- a/runtime/vm/heap/safepoint.h
+++ b/runtime/vm/heap/safepoint.h
@@ -233,6 +233,7 @@
 class TransitionVMToBlocked : public TransitionSafepointState {
  public:
   explicit TransitionVMToBlocked(Thread* T) : TransitionSafepointState(T) {
+    ASSERT(!T->isolate_group()->safepoint_handler()->IsOwnedByTheThread(T));
     // A thread blocked on a monitor is considered to be at a safepoint.
     ASSERT(T->execution_state() == Thread::kThreadInVM);
     T->set_execution_state(Thread::kThreadInBlockedState);
diff --git a/runtime/vm/isolate.cc b/runtime/vm/isolate.cc
index 0667421..222e5a3 100644
--- a/runtime/vm/isolate.cc
+++ b/runtime/vm/isolate.cc
@@ -426,7 +426,7 @@
 }
 
 bool IsolateGroup::ContainsOnlyOneIsolate() {
-  SafepointWriteRwLocker ml(Thread::Current(), isolates_lock_.get());
+  SafepointReadRwLocker ml(Thread::Current(), isolates_lock_.get());
   return isolate_count_ == 0;
 }
 
diff --git a/runtime/vm/isolate_reload_test.cc b/runtime/vm/isolate_reload_test.cc
index c373d3d..6050dd30 100644
--- a/runtime/vm/isolate_reload_test.cc
+++ b/runtime/vm/isolate_reload_test.cc
@@ -2364,7 +2364,7 @@
 
   // Keep track of how many subclasses an Stopwatch has.
   auto& subclasses =
-      GrowableObjectArray::Handle(stopwatch_cls.direct_subclasses());
+      GrowableObjectArray::Handle(stopwatch_cls.direct_subclasses_unsafe());
   intptr_t saved_subclass_count = subclasses.IsNull() ? 0 : subclasses.Length();
 
   const char* kScript =
@@ -2383,7 +2383,7 @@
   }
 
   // Stopwatch has one non-core subclass.
-  subclasses = stopwatch_cls.direct_subclasses();
+  subclasses = stopwatch_cls.direct_subclasses_unsafe();
   EXPECT_EQ(saved_subclass_count + 1, subclasses.Length());
 
   // The new subclass is named AStopwatch.
@@ -2410,7 +2410,7 @@
   }
 
   // Stopwatch still has only one non-core subclass (AStopwatch is gone).
-  subclasses = stopwatch_cls.direct_subclasses();
+  subclasses = stopwatch_cls.direct_subclasses_unsafe();
   EXPECT_EQ(saved_subclass_count + 1, subclasses.Length());
 
   // The new subclass is named BStopwatch.
@@ -2431,7 +2431,7 @@
 
   // Keep track of how many subclasses an Stopwatch has.
   auto& subclasses =
-      GrowableObjectArray::Handle(stopwatch_cls.direct_subclasses());
+      GrowableObjectArray::Handle(stopwatch_cls.direct_subclasses_unsafe());
   intptr_t saved_subclass_count = subclasses.IsNull() ? 0 : subclasses.Length();
 
   const char* kScript =
@@ -2450,7 +2450,7 @@
   }
 
   // Stopwatch has one new subclass.
-  subclasses = stopwatch_cls.direct_subclasses();
+  subclasses = stopwatch_cls.direct_subclasses_unsafe();
   EXPECT_EQ(saved_subclass_count + 1, subclasses.Length());
 
   // The new subclass is named AStopwatch.
@@ -2474,7 +2474,7 @@
   }
 
   // Stopwatch has two non-core subclasses.
-  subclasses = stopwatch_cls.direct_subclasses();
+  subclasses = stopwatch_cls.direct_subclasses_unsafe();
   EXPECT_EQ(saved_subclass_count + 2, subclasses.Length());
 
   // The non-core subclasses are AStopwatch and BStopwatch.
@@ -2500,7 +2500,7 @@
 
   // Keep track of how many subclasses an Stopwatch has.
   auto& subclasses =
-      GrowableObjectArray::Handle(stopwatch_cls.direct_subclasses());
+      GrowableObjectArray::Handle(stopwatch_cls.direct_subclasses_unsafe());
   intptr_t saved_subclass_count = subclasses.IsNull() ? 0 : subclasses.Length();
 
   const char* kScript =
@@ -2524,11 +2524,11 @@
   }
 
   // Stopwatch has one non-core subclass...
-  subclasses = stopwatch_cls.direct_subclasses();
+  subclasses = stopwatch_cls.direct_subclasses_unsafe();
   EXPECT_EQ(saved_subclass_count + 1, subclasses.Length());
 
   // ... and the non-core subclass is named AStopwatch.
-  subclasses = stopwatch_cls.direct_subclasses();
+  subclasses = stopwatch_cls.direct_subclasses_unsafe();
   new_subclass = subclasses.At(subclasses.Length() - 1);
   name = Class::Cast(new_subclass).Name();
   EXPECT_STREQ("AStopwatch", name.ToCString());
@@ -2556,7 +2556,7 @@
   // If we don't clean up the subclasses, we would find BStopwatch in
   // the list of subclasses, which would be bad.  Make sure that
   // Stopwatch still has only one non-core subclass...
-  subclasses = stopwatch_cls.direct_subclasses();
+  subclasses = stopwatch_cls.direct_subclasses_unsafe();
   EXPECT_EQ(saved_subclass_count + 1, subclasses.Length());
 
   // ...and the non-core subclass is still named AStopwatch.
diff --git a/runtime/vm/object.cc b/runtime/vm/object.cc
index 5365462..82605a8 100644
--- a/runtime/vm/object.cc
+++ b/runtime/vm/object.cc
@@ -23821,8 +23821,10 @@
   Zone* zone = thread->zone();
   const SendPort& send_port =
       SendPort::Handle(zone, SendPort::New(id, thread->isolate()->origin_id()));
+#if !defined(PRODUCT)
   const StackTrace& allocation_location_ =
       HasStack() ? GetCurrentStackTrace(0) : StackTrace::Handle();
+#endif  // !defined(PRODUCT)
 
   ReceivePort& result = ReceivePort::Handle(zone);
   {
@@ -23831,9 +23833,11 @@
     NoSafepointScope no_safepoint;
     result ^= raw;
     result.StorePointer(&result.raw_ptr()->send_port_, send_port.raw());
+#if !defined(PRODUCT)
     result.StorePointer(&result.raw_ptr()->debug_name_, debug_name.raw());
     result.StorePointer(&result.raw_ptr()->allocation_location_,
                         allocation_location_.raw());
+#endif  // !defined(PRODUCT)
   }
   if (is_control_port) {
     PortMap::SetPortState(id, PortMap::kControlPort);
diff --git a/runtime/vm/object.h b/runtime/vm/object.h
index 13079ee..85add6f 100644
--- a/runtime/vm/object.h
+++ b/runtime/vm/object.h
@@ -1194,6 +1194,8 @@
 
   // Returns the list of classes directly implementing this class.
   GrowableObjectArrayPtr direct_implementors() const {
+    DEBUG_ASSERT(
+        IsolateGroup::Current()->program_lock()->IsCurrentThreadReader());
     return raw_ptr()->direct_implementors_;
   }
   void AddDirectImplementor(const Class& subclass, bool is_mixin) const;
@@ -1201,6 +1203,11 @@
 
   // Returns the list of classes having this class as direct superclass.
   GrowableObjectArrayPtr direct_subclasses() const {
+    DEBUG_ASSERT(
+        IsolateGroup::Current()->program_lock()->IsCurrentThreadReader());
+    return direct_subclasses_unsafe();
+  }
+  GrowableObjectArrayPtr direct_subclasses_unsafe() const {
     return raw_ptr()->direct_subclasses_;
   }
   void AddDirectSubclass(const Class& subclass) const;
@@ -10559,11 +10566,13 @@
   InstancePtr handler() const { return raw_ptr()->handler_; }
   void set_handler(const Instance& value) const;
 
+#if !defined(PRODUCT)
   StackTracePtr allocation_location() const {
     return raw_ptr()->allocation_location_;
   }
 
   StringPtr debug_name() const { return raw_ptr()->debug_name_; }
+#endif
 
   static intptr_t InstanceSize() {
     return RoundedAllocationSize(sizeof(ReceivePortLayout));
diff --git a/runtime/vm/object_service.cc b/runtime/vm/object_service.cc
index acdaca6..e99a13d 100644
--- a/runtime/vm/object_service.cc
+++ b/runtime/vm/object_service.cc
@@ -154,7 +154,7 @@
   {
     JSONArray subclasses_array(&jsobj, "subclasses");
     const GrowableObjectArray& subclasses =
-        GrowableObjectArray::Handle(direct_subclasses());
+        GrowableObjectArray::Handle(direct_subclasses_unsafe());
     if (!subclasses.IsNull()) {
       Class& subclass = Class::Handle();
       for (intptr_t i = 0; i < subclasses.Length(); ++i) {
diff --git a/runtime/vm/raw_object.h b/runtime/vm/raw_object.h
index a124ad5..91a2ddc 100644
--- a/runtime/vm/raw_object.h
+++ b/runtime/vm/raw_object.h
@@ -2726,9 +2726,13 @@
   VISIT_FROM(ObjectPtr, send_port_)
   SendPortPtr send_port_;
   InstancePtr handler_;
+#if !defined(PRODUCT)
   StringPtr debug_name_;
   StackTracePtr allocation_location_;
   VISIT_TO(ObjectPtr, allocation_location_)
+#else
+  VISIT_TO(ObjectPtr, handler_);
+#endif  // !defined(PRODUCT)
 };
 
 class TransferableTypedDataLayout : public InstanceLayout {
diff --git a/runtime/vm/raw_object_fields.cc b/runtime/vm/raw_object_fields.cc
index f5089d9..d810d3d 100644
--- a/runtime/vm/raw_object_fields.cc
+++ b/runtime/vm/raw_object_fields.cc
@@ -171,8 +171,6 @@
   F(ExternalTypedData, length_)                                                \
   F(ReceivePort, send_port_)                                                   \
   F(ReceivePort, handler_)                                                     \
-  F(ReceivePort, debug_name_)                                                  \
-  F(ReceivePort, allocation_location_)                                         \
   F(StackTrace, async_link_)                                                   \
   F(StackTrace, code_array_)                                                   \
   F(StackTrace, pc_offset_array_)                                              \
@@ -211,6 +209,10 @@
   F(Field, type_test_cache_)                                                   \
   F(WeakSerializationReference, target_)
 
+#define NON_PRODUCT_CLASSES_AND_FIELDS(F)                                      \
+  F(ReceivePort, debug_name_)                                                  \
+  F(ReceivePort, allocation_location_)
+
 OffsetsTable::OffsetsTable(Zone* zone) : cached_offsets_(zone) {
   for (intptr_t i = 0; offsets_table[i].class_id != -1; ++i) {
     OffsetsTableEntry entry = offsets_table[i];
@@ -230,6 +232,10 @@
 // clang-format off
 OffsetsTable::OffsetsTableEntry OffsetsTable::offsets_table[] = {
     COMMON_CLASSES_AND_FIELDS(DEFINE_OFFSETS_TABLE_ENTRY)
+#if !defined(PRODUCT)
+    NON_PRODUCT_CLASSES_AND_FIELDS(DEFINE_OFFSETS_TABLE_ENTRY)
+#endif
+
 #if defined(DART_PRECOMPILED_RUNTIME)
     AOT_CLASSES_AND_FIELDS(DEFINE_OFFSETS_TABLE_ENTRY)
 #else
diff --git a/runtime/vm/service_event.cc b/runtime/vm/service_event.cc
index 00d7ba3..145c9be 100644
--- a/runtime/vm/service_event.cc
+++ b/runtime/vm/service_event.cc
@@ -34,18 +34,23 @@
       bytes_(NULL),
       bytes_length_(0),
       timestamp_(OS::GetCurrentTimeMillis()) {
-  // We should never generate events for the vm isolate as it is never reported over the service.
+  // We should never generate events for the vm isolate as it is never reported
+  // over the service.
   ASSERT(isolate_ != Dart::vm_isolate());
 
-  // System isolates should never post service events. However, the Isolate service object uses a
-  // service event to represent the current running state of the isolate, so we need to allow for
-  // system isolates to create resume and none events for this purpose. The resume event represents
-  // a running isolate and the none event is returned for an isolate that has not yet been marked as
-  // runnable (see "pauseEvent" in Isolate::PrintJSON).
+  // System isolates should never post service events. However, the Isolate
+  // service object uses a service event to represent the current running state
+  // of the isolate, so we need to allow for system isolates to create resume
+  // and none events for this purpose. The resume event represents a running
+  // isolate and the none event is returned for an isolate that has not yet
+  // been marked as runnable (see "pauseEvent" in Isolate::PrintJSON).
   ASSERT(isolate == NULL || !Isolate::IsSystemIsolate(isolate) ||
          (Isolate::IsSystemIsolate(isolate) &&
           (event_kind == ServiceEvent::kResume ||
-           event_kind == ServiceEvent::kNone)));
+           event_kind == ServiceEvent::kNone ||
+           // VM service can print Observatory information to Stdout or Stderr
+           // which are embedder streams.
+           event_kind == ServiceEvent::kEmbedder)));
 
   if ((event_kind == ServiceEvent::kPauseStart) ||
       (event_kind == ServiceEvent::kPauseExit)) {
diff --git a/tests/language/const/syntax_test.dart b/tests/language/const/syntax_test.dart
index 355535a..cf1ce3a 100644
--- a/tests/language/const/syntax_test.dart
+++ b/tests/language/const/syntax_test.dart
@@ -63,7 +63,7 @@
 //        ^
 // [cfe] The const variable 'F3' must be initialized.
 //          ^
-// [cfe] A value of type 'Null' can't be assigned to a variable of type 'int' because 'Null' is nullable and 'int' isn't.
+// [cfe] The value 'null' can't be assigned to a variable of type 'int' because 'int' is not nullable.
 
 class Point {
   final x, y;
diff --git a/tests/language/if_null/precedence_test.dart b/tests/language/if_null/precedence_test.dart
index 574e616..3a198d1 100644
--- a/tests/language/if_null/precedence_test.dart
+++ b/tests/language/if_null/precedence_test.dart
@@ -56,7 +56,7 @@
   // [cfe] Operand of null-aware operation '??' has type 'bool' which excludes null.
   //                                         ^^^^
   // [analyzer] COMPILE_TIME_ERROR.NON_BOOL_OPERAND
-  // [cfe] A value of type 'Null' can't be assigned to a variable of type 'bool' because 'Null' is nullable and 'bool' isn't.
+  // [cfe] The value 'null' can't be assigned to a variable of type 'bool' because 'bool' is not nullable.
   //                                                 ^^^^
   // [analyzer] STATIC_WARNING.DEAD_NULL_AWARE_EXPRESSION
 }
diff --git a/tests/language/nnbd/boolean_conversion/boolean_conversion_error_test.dart b/tests/language/nnbd/boolean_conversion/boolean_conversion_error_test.dart
index 018a408..4a0527c 100644
--- a/tests/language/nnbd/boolean_conversion/boolean_conversion_error_test.dart
+++ b/tests/language/nnbd/boolean_conversion/boolean_conversion_error_test.dart
@@ -57,47 +57,47 @@
     if (nil) {}
     //  ^^^
     // [analyzer] COMPILE_TIME_ERROR.NON_BOOL_CONDITION
-    // [cfe] A value of type 'Null' can't be assigned to a variable of type 'bool' because 'Null' is nullable and 'bool' isn't.
+    // [cfe] A value of type 'Null' can't be assigned to a variable of type 'bool' because 'bool' is not nullable.
     [if (nil) 3];
     //   ^^^
     // [analyzer] COMPILE_TIME_ERROR.NON_BOOL_CONDITION
-    // [cfe] A value of type 'Null' can't be assigned to a variable of type 'bool' because 'Null' is nullable and 'bool' isn't.
+    // [cfe] A value of type 'Null' can't be assigned to a variable of type 'bool' because 'bool' is not nullable.
     nil ? 3 : 4;
 //  ^^^
 // [analyzer] COMPILE_TIME_ERROR.NON_BOOL_CONDITION
-// [cfe] A value of type 'Null' can't be assigned to a variable of type 'bool' because 'Null' is nullable and 'bool' isn't.
+// [cfe] A value of type 'Null' can't be assigned to a variable of type 'bool' because 'bool' is not nullable.
     while (nil) {}
     //     ^^^
     // [analyzer] COMPILE_TIME_ERROR.NON_BOOL_CONDITION
-    // [cfe] A value of type 'Null' can't be assigned to a variable of type 'bool' because 'Null' is nullable and 'bool' isn't.
+    // [cfe] A value of type 'Null' can't be assigned to a variable of type 'bool' because 'bool' is not nullable.
     do {} while (nil);
     //           ^^^
     // [analyzer] COMPILE_TIME_ERROR.NON_BOOL_CONDITION
-    // [cfe] A value of type 'Null' can't be assigned to a variable of type 'bool' because 'Null' is nullable and 'bool' isn't.
+    // [cfe] A value of type 'Null' can't be assigned to a variable of type 'bool' because 'bool' is not nullable.
     nil || true;
 //  ^^^
 // [analyzer] COMPILE_TIME_ERROR.NON_BOOL_OPERAND
-// [cfe] A value of type 'Null' can't be assigned to a variable of type 'bool' because 'Null' is nullable and 'bool' isn't.
+// [cfe] A value of type 'Null' can't be assigned to a variable of type 'bool' because 'bool' is not nullable.
     nil && true;
 //  ^^^
 // [analyzer] COMPILE_TIME_ERROR.NON_BOOL_OPERAND
-// [cfe] A value of type 'Null' can't be assigned to a variable of type 'bool' because 'Null' is nullable and 'bool' isn't.
+// [cfe] A value of type 'Null' can't be assigned to a variable of type 'bool' because 'bool' is not nullable.
     true || nil;
     //      ^^^
     // [analyzer] COMPILE_TIME_ERROR.NON_BOOL_OPERAND
-    // [cfe] A value of type 'Null' can't be assigned to a variable of type 'bool' because 'Null' is nullable and 'bool' isn't.
+    // [cfe] A value of type 'Null' can't be assigned to a variable of type 'bool' because 'bool' is not nullable.
     true && nil;
     //      ^^^
     // [analyzer] COMPILE_TIME_ERROR.NON_BOOL_OPERAND
-    // [cfe] A value of type 'Null' can't be assigned to a variable of type 'bool' because 'Null' is nullable and 'bool' isn't.
+    // [cfe] A value of type 'Null' can't be assigned to a variable of type 'bool' because 'bool' is not nullable.
     for (int i = 0; nil; i++) {}
     //              ^^^
     // [analyzer] COMPILE_TIME_ERROR.NON_BOOL_CONDITION
-    // [cfe] A value of type 'Null' can't be assigned to a variable of type 'bool' because 'Null' is nullable and 'bool' isn't.
+    // [cfe] A value of type 'Null' can't be assigned to a variable of type 'bool' because 'bool' is not nullable.
     [for (int i = 0; nil; i++) 3];
     //               ^^^
     // [analyzer] COMPILE_TIME_ERROR.NON_BOOL_CONDITION
-    // [cfe] A value of type 'Null' can't be assigned to a variable of type 'bool' because 'Null' is nullable and 'bool' isn't.
+    // [cfe] A value of type 'Null' can't be assigned to a variable of type 'bool' because 'bool' is not nullable.
   }
   {
     // Check that values of type `Object` are not usable as booleans.
diff --git a/tests/language/nnbd/experiment_release_version/opt_in_test.dart b/tests/language/nnbd/experiment_release_version/opt_in_test.dart
index a5ea27c..b6334ed 100644
--- a/tests/language/nnbd/experiment_release_version/opt_in_test.dart
+++ b/tests/language/nnbd/experiment_release_version/opt_in_test.dart
@@ -11,5 +11,5 @@
   int x = null;
   //      ^^^^
   // [analyzer] COMPILE_TIME_ERROR.INVALID_ASSIGNMENT
-  // [cfe] A value of type 'Null' can't be assigned to a variable of type 'int' because 'Null' is nullable and 'int' isn't.
+  // [cfe] The value 'null' can't be assigned to a variable of type 'int' because 'int' is not nullable.
 }
diff --git a/tests/language/nnbd/never/never_null_assignability_error_test.dart b/tests/language/nnbd/never/never_null_assignability_error_test.dart
index cb1a99b..ee485d9 100644
--- a/tests/language/nnbd/never/never_null_assignability_error_test.dart
+++ b/tests/language/nnbd/never/never_null_assignability_error_test.dart
@@ -29,7 +29,7 @@
     takesNever(nil);
     //         ^^^
     // [analyzer] COMPILE_TIME_ERROR.ARGUMENT_TYPE_NOT_ASSIGNABLE
-    // [cfe] The argument type 'Null' can't be assigned to the parameter type 'Never' because 'Null' is nullable and 'Never' isn't.
+    // [cfe] The argument type 'Null' can't be assigned to the parameter type 'Never' because 'Never' is not nullable.
     takesNever(never);
     takesNever(3 as dynamic);
     (takesNever as dynamic)(3);
@@ -41,7 +41,7 @@
     takesInt(nil);
     //       ^^^
     // [analyzer] COMPILE_TIME_ERROR.ARGUMENT_TYPE_NOT_ASSIGNABLE
-    // [cfe] The argument type 'Null' can't be assigned to the parameter type 'int' because 'Null' is nullable and 'int' isn't.
+    // [cfe] The argument type 'Null' can't be assigned to the parameter type 'int' because 'int' is not nullable.
     takesInt(nil as dynamic);
     (takesInt as dynamic)(nil);
     (takesInt as dynamic)("hello");
@@ -53,7 +53,7 @@
     takesObject(nil);
     //          ^^^
     // [analyzer] COMPILE_TIME_ERROR.ARGUMENT_TYPE_NOT_ASSIGNABLE
-    // [cfe] The argument type 'Null' can't be assigned to the parameter type 'Object' because 'Null' is nullable and 'Object' isn't.
+    // [cfe] The argument type 'Null' can't be assigned to the parameter type 'Object' because 'Object' is not nullable.
     takesObject(nil as dynamic);
     (takesObject as dynamic)(nil);
   }
@@ -205,12 +205,12 @@
   // ^
   // [analyzer] unspecified
   //      ^
-  // [cfe] A value of type 'Null' can't be assigned to a variable of type 'Never' because 'Null' is nullable and 'Never' isn't.
+  // [cfe] The value 'null' can't be assigned to a variable of type 'Never' because 'Never' is not nullable.
   never = nil;
   // ^
   // [analyzer] unspecified
   //      ^
-  // [cfe] A value of type 'Null' can't be assigned to a variable of type 'Never' because 'Null' is nullable and 'Never' isn't.
+  // [cfe] A value of type 'Null' can't be assigned to a variable of type 'Never' because 'Never' is not nullable.
   nil = never;
   testNullSafeCalls();
   testNullSafeApply();
diff --git a/tests/language/nnbd/syntax/class_member_declarations_error_test.dart b/tests/language/nnbd/syntax/class_member_declarations_error_test.dart
index e1fcf51..e78643e 100644
--- a/tests/language/nnbd/syntax/class_member_declarations_error_test.dart
+++ b/tests/language/nnbd/syntax/class_member_declarations_error_test.dart
@@ -34,7 +34,7 @@
   // [cfe] The modifier 'late' should be before the modifier 'final'.
   //                        ^^^^
   // [analyzer] COMPILE_TIME_ERROR.INVALID_ASSIGNMENT
-  // [cfe] A value of type 'Null' can't be assigned to a variable of type 'A' because 'Null' is nullable and 'A' isn't.
+  // [cfe] The value 'null' can't be assigned to a variable of type 'A' because 'A' is not nullable.
 
   covariant late x15;
   //        ^^^^
diff --git a/tests/language/nnbd/typedef/typedef_error_test.dart b/tests/language/nnbd/typedef/typedef_error_test.dart
index e6e1a82..76c8f69 100644
--- a/tests/language/nnbd/typedef/typedef_error_test.dart
+++ b/tests/language/nnbd/typedef/typedef_error_test.dart
@@ -14,7 +14,7 @@
   F f = null; // typedefs from opted out libraries are treated as non-nullable
   //    ^^^^
   // [analyzer] COMPILE_TIME_ERROR.INVALID_ASSIGNMENT
-  // [cfe] A value of type 'Null' can't be assigned to a variable of type 'int Function(int)' because 'Null' is nullable and 'int Function(int)' isn't.
+  // [cfe] The value 'null' can't be assigned to a variable of type 'int Function(int)' because 'int Function(int)' is not nullable.
 
   f = takesNonNullable; // F is int* Function(int*)
   f(null); // F is int* Function(int*)
diff --git a/tools/VERSION b/tools/VERSION
index 25b9347..5928929 100644
--- a/tools/VERSION
+++ b/tools/VERSION
@@ -27,5 +27,5 @@
 MAJOR 2
 MINOR 12
 PATCH 0
-PRERELEASE 28
+PRERELEASE 29
 PRERELEASE_PATCH 0
\ No newline at end of file